Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pwil3058/dunnart
LALR(1) Parser Generator for the D Programming Language
https://github.com/pwil3058/dunnart
Last synced: about 2 hours ago
JSON representation
LALR(1) Parser Generator for the D Programming Language
- Host: GitHub
- URL: https://github.com/pwil3058/dunnart
- Owner: pwil3058
- Created: 2013-03-06T05:09:36.000Z (over 11 years ago)
- Default Branch: master
- Last Pushed: 2017-07-14T04:25:40.000Z (over 7 years ago)
- Last Synced: 2024-05-02T21:05:04.400Z (7 months ago)
- Language: D
- Size: 337 KB
- Stars: 14
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-d - dunnart - LALR(1) Parser Generator written in D. (Lexers, Parsers, Parser Generators / Bare metal / kernel development)
README
Dunnart D Parser Generator (ddpg)
=================================Enhanced LALR(1) Parser Generator for the D Programming Language.
This (ddgp) tool is an implementation in D of the LALR(1) parser generators
described in "Compilers - Principles, Techniques and Tools" (Aho, Sethi
and Ullman, 1986) (aka the red dragon book) with modifications to allow
conflict resolution using boolean predicates and a built in lexical
analyser. It produces a single D file as output.The [specification language](https://github.com/pwil3058/dunnart/wiki/Specification-Language)
for dunnart (in itself) is described (in the
specification language for dunnart) in the file dunnart.ddgs which was
used to implement the ddpg program recursively via a three stage
bootstrap process (one stage now permanently retired).Building ddgp
=============To build __ddgp__ execute the following:
```
$ make
```
in the base directory.Synopsis
========
```
ddgp []
Options:
-f|--force:
overwrite existing output file
-m | --module=:
insert a "module" statement in the output file using name
-v | --verbose:
produce a full description of the grammar generated
-o | --output= | --prefix=:
if using a path name based on the module name prefix it with path
-e | --expect=:
expect exactly "number" total conflicts
-s | --states=:
write a textual description of the parser's states to "path"
to assist in resolution of any conflicts```
Output File Name
================
If the _--module_ option is used the output filename will be derived
from the module name (prefixed with the argument to the _--prefix_
option if present) unless it is overruled by the _--output_ option.
If neither the _--module_ nor _--output_ option are present, the output
filename will be constructed by replacing the input filename's suffix
with "d".In no event, will an existing file be overwritten unless the _--force_
option is used.License
=======
Dunnart D Parser Generator (ddpg) is licensed under the Boost Software
License, Version 1.0. (See accompanying file LICENSE_1_0.txt or
[copy at](http://www.boost.org/LICENSE_1_0.txt)).