...
Johannes Luber (Maintainer)
jaluber AT gmx.de
Kunle Odutola
kunle UNDERSCORE odutola AT hotmail.com
Micheal Jordan
Contents
...
If you want to setup and start using ANTLR with C# as quickly as possible please see the FAQ page on using ANTLR, ANTLRWorks, and CC#.
However this current page (not the FAQ page) provides architectural and background information useful to understanding the workings and usage of ANTLR and C#.
...
For an example grammar named MyGrammar
, the following table list the files that would be generated by ANTLR 3.1+ using the CSharp2
(and CSharp
) target.
Panel |
---|
bgColor | #FFFFFF |
---|
borderStyle | none |
---|
title | MyGrammar.g | borderStyle | none |
---|
| Code Block |
---|
grammar MyGrammar;
options
{
language=CSharp2;
}
// rest of grammar follows
....
|
|
| Panel |
---|
bgColor | #FFFFFF |
---|
borderStyle | none |
---|
| MyGrammarLexer.cs MyGrammarParser.cs |
| |
Panel |
---|
bgColor | #FFFFFF |
---|
borderStyle | none |
---|
title | MyGrammar.g | borderStyle | none |
---|
| Code Block |
---|
lexer grammar MyGrammar;
options
{
language=CSharp2;
}
// rest of grammar follows
....
|
|
| Panel |
---|
bgColor | #FFFFFF |
---|
borderStyle | none |
---|
| MyGrammar.cs |
| Under ANLTR 3.0.x: MyGrammarLexer.cs
|
Panel |
---|
bgColor | #FFFFFF |
---|
borderStyle | none |
---|
title | MyGrammar.g |
---|
borderStyle | none |
---|
| Code Block |
---|
parser grammar MyGrammar;
options
{
language=CSharp2;
}
// rest of grammar follows
....
|
|
| Panel |
---|
bgColor | #FFFFFF |
---|
borderStyle | none |
---|
| MyGrammar.cs |
| Under ANLTR 3.0.x: MyGrammarParser.cs |
Panel |
---|
bgColor | #FFFFFF |
---|
borderStyle | none |
---|
title | MyGrammar.g | borderStyle | none |
---|
| Code Block |
---|
tree grammar MyGrammar;
options
{
language=CSharp2;
}
// rest of grammar follows
....
|
|
| Panel |
---|
bgColor | #FFFFFF |
---|
borderStyle | none |
---|
| MyGrammar.cs |
| |
...