Skip to content

Commit

Permalink
format grammar files with Antlr4Formatter
Browse files Browse the repository at this point in the history
  • Loading branch information
albertocavalcante committed Sep 11, 2024
1 parent f8fbbb7 commit 28c65a7
Show file tree
Hide file tree
Showing 38 changed files with 3,881 additions and 2,813 deletions.
16 changes: 13 additions & 3 deletions examples/antlr4-opt/Hello/src/main/antlr4/Hello.g4
Original file line number Diff line number Diff line change
@@ -1,4 +1,14 @@
grammar Hello;
r : 'hello' ID ; // match keyword hello followed by an identifier
ID : [a-z]+ ; // match lower-case identifiers
WS : [ \t\r\n]+ -> skip ; // skip spaces, tabs, newlines

r
: 'hello' ID
; // match keyword hello followed by an identifier

ID
: [a-z]+
; // match lower-case identifiers

WS
: [ \t\r\n]+ -> skip
; // skip spaces, tabs, newlines

Loading

0 comments on commit 28c65a7

Please sign in to comment.