lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

On Thu, Oct 18, 2007 at 11:45:53AM -0700, Brent Fulgham wrote:
> Can more magic be used to handle this in the lexer?

You should think very hard about whether you want to be able to
interpret the previous language in the first place.

It may be a better idea, long term, to convert all the old scripts to
the lua syntax, which it seems sed or equivalents can do handily, and
then remove the converter, and the old scripts if you can, from the
hands of your users.  A little brutal maybe, but the syntax is close
enough that the adaptation required of the users should be relatively
simple.  Then they'll work from the converted scripts, which will be

If you convert on the fly, as you propose to do, the users will have
no incentive to learn lua.  They'll only learn some things as they
need it (like if, I presume), and you'll end up with the
frankesteinian horror of something that won't be either your old
syntax nor lua.  And sed scripts may not be sufficient at that point.