[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: PATCH: hex numbers and bit ops
- From: Rici Lake <lua@...>
- Date: Mon, 5 Sep 2005 09:28:18 -0500
On 5-Sep-05, at 3:26 AM, Mike Pall wrote:
BTW: Has anyone noticed that the following:
is accepted by the lexer as valid Lua code (with or without
I guess most tools parsing Lua files won't handle this
Yeah, LuaParse tries to get this "right" but I can't say that I'm very
fond of this behaviour.
e=1f=2 <-- two statements
f=1e=2 <-- error
On 5-Sep-05, at 5:47 AM, Luiz Henrique de Figueiredo wrote:
Why shouldn't it? It may be ugly but it's valid.
Hence my insistence on reusing the Lua lexer...
I don't think it's entirely reasonable to expect every
editor/source-code-highlighter/... in the world to incorporate Lua's
lexer in order to syntax highlight Lua. Lua is *much* easier to lex
than Perl, and somewhat easier to lex than Python, but getting rid of a
few rough edges wouldn't hurt, imho.