[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: need for LuaLint? (Re: Experience with Large Applications in Lua?)
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Wed, 7 Jul 2004 14:35:31 -0300
> > This suggests the need for a library to parse Lua programs into Lua data
> > structures (and vice-versa though not for this case). That way one could
> > write the Lua analysis tools in Lua.
>
> ltokens might doen that(?)
> http://www.tecgraf.puc-rio.br/~lhf/ftp/lua/
Yes, ltokens is a first step. I think it's important to reuse Lua's lexer
because it'll ensure consistency with what Lua does see.
It would be really nice to be able to reuse Lua's parser and get a parse
tree not just a stream of tokens. But I can't see how to do that. It does
not seem too hard to edit lparser.c and make it build a parse tree. But my
point is doing that *without* surgery.
--lhf