Download

SDF: Modular Syntax Definition Formalism

Parser and Parser Generator

The easiest way to get an SDF parser and parser generator is to install the SDF2 Bundle. The current release is:

Previous releases:

The SDF2 Bundle is a collection of packages that implement the SDF2 syntax definition formalism. The individual packages can be downloaded as well, and you can create a bundle of all the software you need at the package base of the CWI. The main packages of the SDF2 Bundle are:

  • PGEN -- a parse table generator for SDF2
  • SGLR -- a scannerless generalized LR parser

Other Software

API Generation

  • ApiGen generates C or Java APIs from an SDF syntax definition.

  • Strafunski and Sdf2Haskell provide support for generic programming and language processing in the functional programming language Haskell. Sdf2Haskell implements the derivation of algebraic datatypes from SDF syntax definitions. The Haskell ATerm library can be used to import the results of the SGLR parser.

  • HaGLR is an implementation of Generalized LR parsing in Haskell, and also implements an SDF front-end, which is an extension of the Sdf2Haskell generator.

Pretty-Printer Generation

  • GPP is a collection of tools for pretty-printing and pretty-printer generation. It supports the SDF syntax definition formalism. GPP is part of StrategoXT.

Testing

Metrics

  • SdfMetz -- A SDF monitoring tool. From the website: "is a tool to support grammar engineering. It calculates metrics and performs miscellaneus analyzes (like output the grammar graph or view the non-singleton levels of a grammar). This tool was implemented to fill the gap of grammar measuring and analyzes tools."