diff options
Diffstat (limited to '')
-rw-r--r-- | dhall_parser/build.rs | 7 | ||||
-rw-r--r-- | dhall_parser/src/dhall.abnf | 9 | ||||
-rw-r--r-- | dhall_parser/src/dhall.pest.visibility | 1 |
3 files changed, 10 insertions, 7 deletions
diff --git a/dhall_parser/build.rs b/dhall_parser/build.rs index 4e75181..615a55c 100644 --- a/dhall_parser/build.rs +++ b/dhall_parser/build.rs @@ -42,13 +42,6 @@ fn main() -> std::io::Result<()> { )?; writeln!( &mut file, - "keyword = _{{ - let_ | in_ | if_ | then - | else_ | Infinity | NaN - }}" - )?; - writeln!( - &mut file, "final_expression = ${{ SOI ~ complete_expression ~ EOI }}" )?; diff --git a/dhall_parser/src/dhall.abnf b/dhall_parser/src/dhall.abnf index 4aa3fec..01ec6d8 100644 --- a/dhall_parser/src/dhall.abnf +++ b/dhall_parser/src/dhall.abnf @@ -291,6 +291,15 @@ Infinity = %x49.6e.66.69.6e.69.74.79 NaN = %x4e.61.4e
Some = %x53.6f.6d.65
+; Unused rule that could be used as negative lookahead in the
+; `simple-label` rule for parsers that support this.
+keyword =
+ if / then / else
+ / let / in
+ / using / missing / as
+ / Infinity / NaN
+ / merge / Some
+
; Reserved identifiers, only needed for some special cases of parsing
Optional = %x4f.70.74.69.6f.6e.61.6c
Text = %x54.65.78.74
diff --git a/dhall_parser/src/dhall.pest.visibility b/dhall_parser/src/dhall.pest.visibility index 63a4179..8205cc8 100644 --- a/dhall_parser/src/dhall.pest.visibility +++ b/dhall_parser/src/dhall.pest.visibility @@ -44,6 +44,7 @@ in_ # using merge # Infinity +# keyword Optional Text List |