Skip to content

Releases: BenchR267/Parsel

Operator fixing

24 Oct 22:04
00ad900
Compare
Choose a tag to compare
  • finally <~ and ~>!
    • also fixed the associativity of <~ (all left now)
  • added playgrounds to the releases + generation in Makefile
  • Added and fixed implementations in Lexical
  • Added code of conduct

Added pattern matching

21 Sep 20:33
e2d56ac
Compare
Choose a tag to compare

This release adds support for using Parsers with Swifts internal pattern matching (switch - case). That means you can write something like

switch "a" {
    case L.char: print("it's a char :)")
    case L.digit: print("it's a digit!")
    default: print("it's something unexpected :/")
}

It will try to parse the value ("a" in the example) with each parser and checks as well if the rest is empty. So only if the complete input matches, the case matches.

Added documentation URL to podspec

29 Aug 09:13
b22a758
Compare
Choose a tag to compare

Beside that only some documentation was added/changed - no production code changes.

Precedence!

27 Aug 15:30
43212cb
Compare
Choose a tag to compare

2.1.0 fixes precedence groups, so operators are better usable. Check out the test cases here if you would like to see them in action.
The release also contains some changed regular expression parsers in RegexParser.swift and changes the shortcut for RegexParser to R. So now you can get a parser for mails with R.mail e.g.

Lexical parsing!

27 Aug 15:27
951427e
Compare
Choose a tag to compare

2.0.0 Adds support for pre-defined parsers for lexical parsing. Lexical parsing is destructuring of String based input.

First official release

27 Aug 15:26
97c5288
Compare
Choose a tag to compare

This release includes the core functionality for build parsers with Parsel. Also on board is the RegexParser, a parser that makes it an ease to create parsers with regular expressions.