On 4 Jun 2009, at 7:01 am, Tony Finch wrote: > LPeg does exactly what you want, though its host language is Lua. > > http://www.inf.puc-rio.br/~roberto/lpeg/lpeg.html > Thanks for that link. My failure to learn Lua is becoming increasingly irrational, especially now that LuaTeX exists.