Implementing Java-like languages in Xtext with Xsemantics
Lorenzo Bettini · 2013
In this paper we present Xsemantics, a DSL for writing type systems, reduction rules and in general relation rules for languages implemented in Xtext. Xsemantics aims at minimizing the gap between the formalization of a language and the actual implementation in Xtext, since it uses a syntax that resembles the typical rules in a formal setting. We present an implementation of FJ (Featherweight Java) in Xtext together with its type system and operational semantics in Xsemantics. We show how such implementation is pretty faithful to the actual formalization of FJ.