Skip to content

0.5.0

Compare
Choose a tag to compare
@kevinmehall kevinmehall released this 15 Jan 20:11
· 254 commits to master since this release

Changes

  • Change #[pub] rule_name = ... syntax to pub rule_name = .... The old syntax is retained for backwards compatibility, but pub is now a reserved keyword and cannot be used as an identifier.

New features

  • Add rule templates
  • Add experimental #infix syntax for parsing binary infix expressions by precedence climbing.
  • Allow delimited-repeat with range bounds **<n,m>.
  • Add x*<{count}> syntax for a repeat bounded by a Rust expression.
  • Add #quiet<e> and #expected("msg") expressions for improved error reporting.
  • Allow as in use statements to match Rust syntax.

Fixes

  • Fix a bug in error reporting of & and ! expressions.
  • Avoid type errors if a rule returns a result, but the result is not used.
  • Error when using a nonexistent rule, rather than generating Rust code that doesn't compile.