A DSL for writing type systems for Xtext languages
- 24 August 2011
- conference paper
- conference paper
- Published by Association for Computing Machinery (ACM)
Abstract
Xtext is a framework for the development of languages, which also generates all the typical and recurrent artifacts for a fully-fledged IDE on top of Eclipse. The validation (e.g., checking the correctness of programs from the point of view of types) of languages developed in Xtext has to be implemented by the programmer writing Java code. In this paper we present XTypeS (Xtext TypeSystem), a DSL for writing the type system for an Xtext language. A type system definition in XTypeS is a set of rules which act on the elements of the AST of a program, which in Xtext is represented by an EMF model. Then, XTypeS will generate the corresponding Java code that can be used to implement the validation part for a language developed in Xtext. We describe the features of XTypeS by writing the type system of two languages implemented in Xtext: Featherweight Java and λ-calculus.Keywords
This publication has 20 references indexed in Scilit:
- MontiCore: a framework for compositional development of domain specific languagesInternational Journal on Software Tools for Technology Transfer, 2010
- Ott: Effective tool support for the working semanticistJournal of Functional Programming, 2010
- Language BoxesLecture Notes in Computer Science, 2010
- Stratego/XT 0.17. A language and toolset for program transformationScience of Computer Programming, 2008
- The JastAdd system — modular extensible compiler constructionScience of Computer Programming, 2007
- MetaBorg in Action: Examples of Domain-Specific Language Embedding and Assimilation Using Stratego/XTLecture Notes in Computer Science, 2006
- Ruler: Programming Type RulesLecture Notes in Computer Science, 2006
- Compiling language definitionsACM Transactions on Programming Languages and Systems, 2002
- Featherweight JavaACM Transactions on Programming Languages and Systems, 2001
- Metal: a formalism to specify formalismsScience of Computer Programming, 1983