ACM SIGPLAN Notices · 2004 · 61 citations · 18 references
ComputingComputer ScienceProgramming LanguagesSoftware EngineeringSyntaxApplication Programming InterfacesDomain-specific LanguagesObject-oriented ProgrammingSoftware ArchitectureSoftware ConstructionSoftware DesignAbstraction MechanismsApplication Programming Interface (Api)Concrete Syntax ModelingEmbedded Domain-specific LanguagesObject-oriented ArchitectureProgram Transformation
Application programmer's interfaces give access to domain knowledge encapsulated in class libraries without providing the appropriate notation for expressing domain composition. Since object-oriented languages are designed for extensibility and reuse, the language constructs are often sufficient for expressing domain abstractions at the semantic level. However, they do not provide the right abstractions at the syntactic level. In this paper we describe MetaBorg, a method for providing <i>concrete syntax</i> for domain abstractions to application programmers. The method consists of <i>embedding</i> domain-specific languages in a general purpose host language and <i>assimilating</i> the embedded domain code into the surrounding host code. Instead of extending the implementation of the host language, the assimilation phase implements domain abstractions in terms of existing APIs leaving the host language undisturbed. Indeed, MetaBorg can be considered a method for promoting APIs to the language level. The method is supported by proven and available technology, i.e. the syntax definition formalism SDF and the program transformation language and toolset Stratego/XT. We illustrate the method with applications in three domains: code generation, XML generation, and user-interface construction.
18
An efficient context-free parsing algorithm
Jay Earley · Communications of the ACM · 1970 · 817 citations · Full text
The syntax definition formalism SDF—reference manual—
Jan Heering, Paul Hendriks, Paul Klint et al. · ACM SIGPLAN Notices · 1989 · 269 citations
Building program optimizers with rewriting strategies
Eelco Visser, Zine-el-Abidine Benaissa, Andrew Tolmach · 1998 · 251 citations · Full text
SableCC, an object-oriented compiler framework
Étienne Gagnon, Laurie Hendren · 2002 · 182 citations · Full text