An Introductory Tutorial on JastAdd Attribute Grammars

  title={An Introductory Tutorial on JastAdd Attribute Grammars},
  author={G{\"o}rel Hedin},
  booktitle={Generative and Transformational Techniques in Software Engineering},
  • G. Hedin
  • Published in
    Generative and…
    6 July 2009
  • Computer Science
JastAdd is an open-source system for generating compilers and other language-based tools. Its declarative specification language is based on reference attribute grammars and object-orientation. This allows tools to be implemented as composable extensible modules, as exemplified by JastAddJ, a complete extensible Java compiler. This tutorial gives an introduction to JastAdd and its core attribute grammar mechanisms, and how to use them when solving key problems in building language-based tools… 

JavaRAG: a Java library for reference attribute grammars

This paper presents JavaRAG, an implementation of RAGs as a Java library that is independent of the abstract syntax tree structure, which makes it possible to extend legacy compilers implemented in Java with RAG computations.

Contributions to Parallelizing JastAdd Compilers

A new analysis which combines simplified code generation for the JastAdd meta-compiler with an existing purity analysis tool extended with further capabilities is presented, which reduces the number of warnings and analysis time for ExtendJ and

Embedding attribute grammars and their extensions using functional zippers

A JastAdd implementation of Oberon-0

Web-based Tree Editor for JastAdd Compilers

This thesis presents a generic web-based tree editor that works for creating programs in any language specified in the metacompilation system JastAdd, and performs semantic analysis and displays semantic errors directly in the web browser.

Name analysis for modern languages: a general solution

The limitations of the classical strategies for matching identifier uses with declarations are explained, the concepts on which the approach is based are presented, and an implementation based on attribute grammars is showcased.

CJC: An Extensible Checker for the CleanJava Annotation Language

This paper describes the experience of developing a CleanJava checker called CJC and explains how it met the above requirements by using an open-source Java compiler.

Integrating Xtext and JavaRAG: Using an attribute grammar library in a language workbench

It is concluded that JavaRAG could be integrated into Xtext without issue, and that it offered beneficial functionality for more complex error-checking problems where Xtext’s own features were sometimes lacking.

Rewriting JGrafchart with Rewritable Reference Attribute Grammars

Making the two textual sub-languages of Grafchart extensible by rewriting them using ReRAGs is focused on, where the sup notation is added as an extension to the ReRAGS implementation to confirm extensibility.

From object algebras to attribute grammars

This work presents an extension of the object algebra technique with which the full class of L-attributed grammars - an important class of AGs that corresponds to one-pass compilers - can be encoded in Scala.



Modular Name Analysis for Java Using JastAdd

It is shown how Java name analysis including ambiguities related to names of variables, fields, and packages, can be implemented in a declarative and modular manner using the JastAdd compiler construction system.

Rewritable Reference Attributed Grammars

ReRAGs is an object-oriented technique for rewriting abstract syntax trees in order to simplify compilation and allows compilers to be written in a high-level declarative and modular fashion, supporting language extensibility as well as reuse of modules for different compiler-related tools.

The jastadd extensible java compiler

The JastAdd Extensible Java Compiler is a high quality Java compiler that is easy to extend in order to build static analysis tools for Java, and to extend Java with new language constructs. It is

Silver: An extensible attribute grammar system

A Pure Object-Oriented Embedding of Attribute Grammars

Reference Attributed Grammars

An object-oriented extension to canonical attribute grammars is described, permitting attributes to be references to arbitrary nodes in the syntax tree, and attributes to be accessed via the

Decorated Attribute Grammars: Attribute Evaluation Meets Strategic Programming

This work proposes attribute decorators that describe an abstract evaluation mechanism for attributes, making it possible to provide such extensions as part of a library of decorators.

Extensible Compiler Construction

Rewritable Reference Attributed Grammars (ReRAGs), a technique that builds on well-known software development techniques such as object-orientation, aspect-oriented software development, declarative programming, attribute grammars, and transformation systems, with synergistic effects on modularity and extensibility is presented.

Remote attribute grammars

It is shown that determining circularity of remote attribute grammars is undecidable and a family of conservative tests of noncircularity are described and shown how they can be used to “schedule” a remote attribute grammar using standard techniques.