Skip to content

v1.1.3

Latest
Compare
Choose a tag to compare
@Byron Byron released this 25 Jul 07:48
f056cef

Bug Fixes

  • last number not identified in an isolated value pair
    I am using the Lexer to parse json chunks that I get in stdin one line at a time.

    I appreciate my use case isn't the intended one for this lib as all the tests deal with fully formed json objects and nowhere it states that this lib will work with chunks. But since it works perfectly for my use case, I thought others might benefit from this fix. But also feel free to ignore it.

    This PR fixes a problem where the last number value won't be identified as a number because numbers don't have a terminator like strings. In normal circumstances the next token would serve as the terminator (comma, curly brackets, etc) but if the number line is the last one in an json object, the string just ends and the object closing curly brace is in the next line so the number gets ignored.

    This fix checks if the last processed token was Number and returns the token type accordingly.

    Happy to add any further improvements or additional tests that would be beneficial

Commit Statistics

  • 8 commits contributed to the release over the course of 1635 calendar days.
  • 1635 days passed between releases.
  • 1 commit was understood as conventional.
  • 0 issues like '(#ID)' were seen in commit messages

Commit Details

view details
  • Uncategorized
    • Avoid using the 'alpha' suffix (1b9c1d7)
    • Last number not identified in an isolated value pair (927c987)
    • Isolated value pairs fix (2b47444)
    • Optimize includes (3fe2df2)
    • Add new badges (3c9fb9e)
    • Add clippy and cargo-fmt lints (6129e80)
    • Create rust.yml (ee18ffa)
    • (cargo-release) start next development iteration 1.1.3-alpha.0 (0668d4a)