-
-
Save greenlaw110/2991022 to your computer and use it in GitHub Desktop.
a problem antlr file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
grammar RL; | |
report | |
: REPORT ('(' REPORT_NAME ')')? BEGIN END | |
; | |
REPORT : 'Report'; | |
BEGIN : 'Begin'; | |
END : 'End'; | |
NAME : LETTER (LETTER | DIGIT | '_')*; | |
REPORT_NAME | |
: NAME+ | |
; | |
fragment LETTER : LOWER | UPPER; | |
fragment LOWER : 'a'..'z'; | |
fragment UPPER : 'A'..'Z'; | |
fragment DIGIT : '0'..'9'; | |
SPACE : (' ' | '\t' | '\r' | '\n')+ { $channel = HIDDEN; }; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment