[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: C with embedded Lua or Lua-only program?
- From: Miles Bader <miles@...>
- Date: Fri, 03 Sep 2010 11:51:00 +0900
Silas Silva <email@example.com> writes:
> 1. Is there any replacement for lex/flex & yacc/bison for Lua? How do
> you design DSLs in Lua? I thought about using Lex & Yacc + C it is a
> long standing wish of mine to learn parsers, BNF with Lex & Yacc...
Use "LPeg" -- it's fast, easy to use, and very expressive, and is well
supported and popular in the Lua community. LPeg can replace both lex
and yacc (just think of a grammar which goes down to the character
Egotist, n. A person of low taste, more interested in himself than in me.