The original question was about a lexer do use with buffalo. PEG parsers
parser to do only the lexer part to use with buffalo.
Optima (and optima.ppcre) is another library that can be used for lexers.
I wish that Iâd had PEG 20 years ago,
PEG parses a wider set of grammars than YACC can.
PEG is backtracking, but, it uses a trick, memoizing, that minimizes the cost of backtracking.
Given the hardware we have these days, I donât see why anyone would use anything but PEG and packrat parsing.
Google phrase âbryan ford pegâ
Building a PEG parser is way, way easier than dealing with Lex and YACC.
Iâm not sure if Iâve answered all of your questions ⊠please feel free to ask again....
pt
Post by Gary KingHi Paul,
What is the performance of Esrap vis-a-vis something like cl-yac? Given a BN grammar, how hard is it to build up a PEG parser?
thanks,
Esrap is a PEG parser. PEG is Lex and Yacc combined. I'm sure that you could use esrap as a lexer-only, if you wish to.
http://nikodemus.github.io/esrap/
On my github there's an experimental PEG syntax overlaid over esrap syntax, if you care. https://github.com/guitarvydas
Ping me if you need ref's to papers about PEG.
pt
_______________________________________________
pro mailing list
https://mailman.common-lisp.net/cgi-bin/mailman/listinfo/pro
--
Gary Warren King, metabang.com
Cell: (413) 559 8738
Fax: (206) 338-4052
gwkkwg on Skype * garethsan on AIM * gwking on twitter
_______________________________________________
pro mailing list
https://mailman.common-lisp.net/cgi-bin/mailman/listinfo/pro
_______________________________________________
pro mailing list
https://mailman.common-lisp.net/cgi-bin/mailman/listinfo/pro