antlr-d 1.5.3
ANTLR4 runtime library
To use this package, run the following command in your project's root directory:
						Manual usage
						
						Put the following dependency into your project's dependences section:
					
Antlr4DTarget
The D runtime library for ANTLR 4, mainly an adaption of original Java runtime library.
This Software is under development but tested on different grammars of ANTLR version 4.7.2 yet.
Install
- Download or clone the package
- Change directory to the root of the package and call dub.
- You will find the generated ATLR D runtime library in lib/libantlr-d.a
- The ANTLR tool for D will generated by make build_examples (./build.ps1 build_examples on windows) in build/antlr4-4.7.2/tool/target/antlr4-4.7.2-complete.jar
Dependencies
ANTLR tool
- java 1.8
- maven
- 7-Zip (Only on windows)
Example
Put the
grammar Expr;		
prog:	(expr NEWLINE)* ;
expr:	expr ('*'|'/') expr
    |	expr ('+'|'-') expr
    |	INT
    |	'(' expr ')'
    ;
NEWLINE : [\r\n]+ ;
INT : [0-9]+ ;
in the file Expr.g4.
Now call
java -jar -Dlanguage=D build/antlr4-4.7.2/tool/target/antlr4-4.7.2-complete.jar Expr.g4
and the correspondig Lexer, Parser and Listener D-Source files are generated.
Restrictions
- UTF-16 support not finished
- 1.5.3 released 6 years ago
- funkwerk-mobility/antlr-d
- BSD
- Copyright (c) 2012-2019 The ANTLR Project. All rights reserved.
- Authors:
- Dependencies:
- none
- Versions:
- 
						
 Show all 49 versions1.8.3 2020-Dec-05 1.8.2 2020-Nov-28 1.8.1 2020-May-05 1.8.0 2020-Apr-24 1.7.4 2020-Apr-20 
- Download Stats:
- 
						- 
								0 downloads today 
- 
								3 downloads this week 
- 
								4 downloads this month 
- 
								388 downloads total 
 
- 
								
- Score:
- 0.6
- Short URL:
- antlr-d.dub.pm