Skip to content

Latest commit

 

History

History
90 lines (65 loc) · 3.62 KB

File metadata and controls

90 lines (65 loc) · 3.62 KB

0.9.4

  • Fix lone statements in parser bodies causing syntax errors if not followed by a return value in the next line
  • Add example indent to demonstrate context-sensitive parsing

0.9.3

  • Add repeat attribute, which accepts both usize and ranges, and matches a pattern within that range or exactly that number of times

0.9.2

  • Implement Deref and DerefMut for Span
  • Add attribute map and alias convert, which can be used like #[map(map_fn)] pattern to convert the output type of a parser
    • Previously you would have to write a new named parser just to convert the output of another parser

0.9.1

  • Fix compiler error in empty match statement when error type is specified
  • Disable unreachable_code lint inside generated code, as it could be generated by empty match statements

0.9.0

  • Add support for match-type parsers (https://github.com/boxbeam/untwine/blob/master/TUTORIAL.md#using-matches)
    • This allows much more concise and intuitive representations for parsers which have many different structures evaluating to the same type
  • Make delimited lists less greedy
    • Previously, if a delimiter was found when parsing a delimited list, it would attempt to parse another element and error if it fails
    • Delimited lists will now consider parsing successful and return what was parsed if there is no element following the delimiter
    • This is useful for structures which allow optional (or required) trailing delimiters, such as 1,2,3,
    • The above can now be expressed like num$","+ ","? instead of num ("," num)* ","?
      • This also allows you to get a Vec<T> instead of a (T, Vec<T>)
  • Add #[span] decorator, which allows you to capture the portion of input corresponding to a parsed value
  • Update examples to reflect new ideal implementations of JSON and boolean expression parsers

0.8.3

  • Fix improper error reporting with lookahead optimization
    • Could sometimes cause panics due to the start position of an error being ahead of the end position, causing an overflow in display code
  • Disable elided_named_lifetimes warning inside parser blocks

0.8.2

  • Make all non-captured parsers use .ignore() to drop their outputs
    • This makes it possible to do things such as #(a | b) where a and b have different types. Since the overall output is ignored, both their outputs will be ignored and the parsers do not have to have the same output type.
  • Add character literals like '"'

0.8.1

  • Fix issue with incomplete parses sometimes not generating any errors
  • Write tutorial

0.8.0

  • Fix some strange error messages
  • Make AppendCell crate-private

0.7.0

  • Overhaul of error handling internals
  • ~20% improvement in parser performance

0.6.1

  • Improve errors for missing delimiters
  • Add some missing documentation

0.6.0

  • Implement automatic error recovery
    • Enabled with recover = true in your parser's configuration block
    • Automatically recovers to the delimiters of delimited lists and of wrapped named rules
      • Wrapped named rules like parens: "(" parens* ")" -> MyType { ... }
  • Remove all runtime dependencies

0.5.0

  • Implement lookahead optimization
    • Automatically generates a match statement at compiletime for choice patterns
    • Looks ahead by one character only
    • ~25% improvement in parser performance

0.4.0

  • Add tests
  • Improve docs

0.3.0

  • Add parser_repl function for easy testing of a simple parser
    • Only intended for debugging, very minimal REPL without scrolling

0.2.0

  • Prettier, more informative errors
  • Error ranges, which point out an error's origin / context as well
  • Implementation of proof of concept parsers
  • Initial working release