diff options
| author | krasimir <krasimir@chalmers.se> | 2016-03-21 13:27:44 +0000 |
|---|---|---|
| committer | krasimir <krasimir@chalmers.se> | 2016-03-21 13:27:44 +0000 |
| commit | c8ebe093150509d9f01d82f0d698ef5df09bd985 (patch) | |
| tree | a35dfd20f40c7461a2fe8809668626c09c9a8a85 /src/compiler/GF/Grammar/Lexer.x | |
| parent | da10bb33c73e0742d6aa3aa77d71b2804b2ed673 (diff) | |
initial support for BNFC syntax in context-free grammars for GF. Not all features are supported yet. Based on contribution from Gleb Lobanov
Diffstat (limited to 'src/compiler/GF/Grammar/Lexer.x')
| -rw-r--r-- | src/compiler/GF/Grammar/Lexer.x | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/compiler/GF/Grammar/Lexer.x b/src/compiler/GF/Grammar/Lexer.x index f073bcdfc..c579b5609 100644 --- a/src/compiler/GF/Grammar/Lexer.x +++ b/src/compiler/GF/Grammar/Lexer.x @@ -124,6 +124,10 @@ data Token | T_variants | T_where | T_with + | T_coercions + | T_terminator + | T_separator + | T_nonempty | T_String String -- string literals | T_Integer Int -- integer literals | T_Double Double -- double precision float literals @@ -212,6 +216,10 @@ resWords = Map.fromList , b "variants" T_variants , b "where" T_where , b "with" T_with + , b "coercions" T_coercions + , b "terminator" T_terminator + , b "separator" T_separator + , b "nonempty" T_nonempty ] where b s t = (identS s, t) |
