hello!
I have created a PEG parser library for racket. It's basically regex
turned up to 11.
It lets you write parsers like this:
(define-peg marked-palindrome
(or "m"
(and "1" marked-palindrome "1")
(and "0" marked-palindrome "0")))
or like this:
#lang peg
expr <- sum ;
sum <-- (product ('+' / '-') sum) / product ;
product <-- (value ('*' / '/') product) / value ;
value <-- number / '(' expr ')' ;
number <-- [0-9]+ ;
It is available from the racket pkgs repository, or on github:
* https://pkgd.racket-lang.org/pkgn/package/peg
* https://github.com/rain-1/racket-peg
I welcome feedback and hope that the library is of use.
--
You received this message because you are subscribed to the Google Groups "Racket
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to racket-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.