- Support for multilingual syntactic extensibility integrated into master branch and available as Eclipse update. Currently supported languages: Java, Haskell, Prolog.
- SugarHaskell paper accepted at Haskell Symposium 2012
- SugarJ Google group: Discuss and stay up-to-date
- Syntactic extensibility for Haskell: SugarHaskell is up and running.
Install it from our Eclipse update site, including IDE support and layout-sensitive parsing.
- What does language composition really mean? Paper at LDTA 2012 [ abstract | .pdf ]
In essence, the goal of SugarJ is to enable expressing programs in the syntax most natural to the problem domain the program is supposed to address. For instance, when generating XML documents in Java, the programmer should be able to use standard XML syntax instead of Java syntax for calling JDOM, say.
We propose to integrate syntactic extensibility into the main extension mechanism of programming languages—libraries. Libraries thus export syntactic sugar in addition to semantic artifacts traditionally exported: classes, methods, data types, etc. When importing a library, the syntax of the general purpose language is augmented by the syntactic definition exported by the library.
Notably, libraries that contain syntactic sugar retain the composability and self-applicability of conventional libraries: syntactic sugar can be composed by importing multiple libraries; syntactic sugar can be used in the development of a library that exports syntactic sugar itself. This enables the embedding of DSLs and the development of meta-DSLs, that is a DSL for defining DSLs, without ever leaving or reasoning outside of a SugarJ program.
Installation and UsagePlease ensure enough stack space (about 4-16 MB) is available for the SDF parser. You can set the stack space of your Java runtime using the -Xss16m command line argument when starting Eclipse or setting -Xss16m in your eclipse.ini file.
For a quick start, install our Eclipse plugin available at http://update.sugarj.org/. The update dialog will let you select any number of our currently supported host languages: Java (*.sugj), Haskell (*.shs), Prolog (*.sugp).
We also prepared some information on first steps with SugarJ.
SubprojectsWe are currently developing a number of extensions of SugarJ. The relevant code can be found as follows:
- Language extensibility for Scala (by Florian Jakob): in repository lang-scala
- Software Evolution to Domain-Specific Languages: See our SLE paper and the Java Pet Store case study
- Models and transformations as modules: A module system for model-driven development
TeamProject lead: Sebastian Erdweg, TU Darmstadt
Get in touch, discuss, or simply stay up-to-date by joining the SugarJ Google group.Contributors:
- Tillmann Rendel, University of Marburg
- Christian Kästner, CMU
- Klaus Ostermann, University of Marburg
- Lennart Kats, Delft University of Technology
- Eelco Visser, Delft University of Technology
- Paolo G. Giarrusso, University of Marburg
- Florian Lorenzen, TU Berlin
- Jonas Pusch, University of Marburg
- Stefan Fehrenbach, University of Marburg
- Felix Rieger, University of Marburg
- Florian Jakob, TU Darmstadt
- Moritz Lichter, TU Darmstadt
A Framework for Extensible Languages
Sebastian Erdweg and Felix Rieger. In Proceedings of Conference on Generative Programming: Concepts & Experiences (GPCE), pages 3–12. ACM, 2013. [ .pdf ]
Extensible Languages for Flexible and Principled Domain Abstraction
Sebastian Erdweg. PhD thesis, Philipps-Universität Marburg, 2013. [ .pdf ]
Embedding a Questionnaire DSL with SugarJ
Sebastian Erdweg. In Proceedings of Language Workbench Challenge (LWC), 2013. [ pdf ]
Layout-sensitive Language Extensibility with SugarHaskell
Sebastian Erdweg, Felix Rieger, Tillmann Rendel, and Klaus Ostermann. In Proceedings of Haskell Symposium, pages 149-160. ACM, 2012. [ .pdf ]
Language Composition Untangled
Sebastian Erdweg, Paolo G. Giarrusso, and Tillmann Rendel. In Proceedings of Workshop on Language Descriptions, Tools and Applications (LDTA), 7:1-7:8. ACM, 2012. [ .pdf ]
Growing a Language Environment with Editor Libraries
Sebastian Erdweg and Lennart C. L. Kats and Tillmann Rendel and Christian Kästner and Klaus Ostermann and Eelco Visser. In Proceedings of Conference on Generative Programming and Component Engineering (GPCE), pages 167–176. ACM, 2011. [ .pdf ]
SugarJ: Library-based Syntactic Language Extensibility
Sebastian Erdweg, Tillmann Rendel, Christian Kästner and Klaus Ostermann. In Proceedings of Conference on Object-Oriented Programming, Systems, Languages, and Applications (OOPSLA), pages 391–406. ACM, 2011. Distinguished Paper Award. [ .pdf ]