skip to main content
10.1145/1066677.1066986acmconferencesArticle/Chapter ViewAbstractPublication PagessacConference Proceedingsconference-collections
Article

Weaving a debugging aspect into domain-specific language grammars

Authors Info & Claims
Published:13 March 2005Publication History

ABSTRACT

A common trend in programming language specification is to generate various tools (e.g., compiler, editor, profiler, and debugger) from a grammar. In such a generative approach, it is desirable to have the definition of a programming language be modularized according to specific concerns specified in the grammar. However, it is often the case that the corresponding properties of the generated tools are scattered and tangled across the language specification. In this paper, separation of concerns within a programming language specification is demonstrated by considering debugging support within a domain-specific language (DSL). The paper first describes the use of AspectJ to weave the debugging semantics into the code created by a parser generator. The paper outlines several situations when the use of AspectJ is infeasible at separating language specification properties. To accommodate such situations, a second approach is presented that weaves the debugging support directly into a grammar specification using a program transformation engine. A case study for a simple DSL is presented to highlight the benefits of weaving across language specifications defined by grammars.

References

  1. The AspectJ web site (http://aspectj.org).]]Google ScholarGoogle Scholar
  2. ANTLR - ANother Tool for Language Recognition, available from http://www.antlr.org/.]]Google ScholarGoogle Scholar
  3. Ira Baxter, Christopher Pidgeon, and Michael Mehlich, "DMS: Program Transformation for Practical Scalable Software Evolution," International Conference on Software Engineering (ICSE), Edinburgh, Scotland, May 2004, pp. 625--634.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Jonathan B. Rosenberg, How Debuggers Work- Algorithms, Data Structures, and Architecture, John Wiley & Sons. Inc, New York, NY, 1996.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Uwe Aßmann, Invasive Software Composition, Springer-Verlag, 2003.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Paul Klint, Ralf Lammel, and Chris Verhoef, "Towards an Engineering Discipline for Grammarware," http://www.cs.vu.nl/grammarware/.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. Marjan Mernik, Matej Crepinsek, Tomaz Kosar, Damijan Rebernak, and Viljem Zumer, "Grammar-Based Systems: Definition and Examples," Journal of Informatica, accepted for publication - 2004.]]Google ScholarGoogle Scholar
  8. Hui Wu, Jeff Gray, and Marjan Mernik, "Debugging Domain-Specific Languages in Eclipse," OOPSLA Eclipse Technology Exchange Poster Session, Vancouver, BC, October 2004.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. Oege de Moor, Simon Peyton-Jones, and Eric Van Wyk, "Aspect-Oriented Compilers," Generative and Component-Based Software Engineering, Springer-Verlag LNCS 1799, September 1999, pp. 121--133.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Görel Hedin and Eva Magnusson, "JastAdd-an Aspect-Oriented Compiler Construction System," Science of Computer Programming, April 2003, pp. 37--58.]] Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. The JUnit web site (http://www.junit.org).]]Google ScholarGoogle Scholar

Index Terms

  1. Weaving a debugging aspect into domain-specific language grammars

          Recommendations

          Comments

          Login options

          Check if you have access through your login credentials or your institution to get full access on this article.

          Sign in
          • Published in

            cover image ACM Conferences
            SAC '05: Proceedings of the 2005 ACM symposium on Applied computing
            March 2005
            1814 pages
            ISBN:1581139640
            DOI:10.1145/1066677

            Copyright © 2005 ACM

            Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

            Publisher

            Association for Computing Machinery

            New York, NY, United States

            Publication History

            • Published: 13 March 2005

            Permissions

            Request permissions about this article.

            Request Permissions

            Check for updates

            Qualifiers

            • Article

            Acceptance Rates

            Overall Acceptance Rate1,650of6,669submissions,25%

          PDF Format

          View or Download as a PDF file.

          PDF

          eReader

          View online with eReader.

          eReader