lua-users home
lua-l archive

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

Luiz Henrique de Figueiredo <> writes:

> >I noticed that certain erroneous programs are accepted by the Lua
> >compiler, but rejected by lsc.  
> These are all semantic errors, not syntactic errors.
> Plus they may not be errors at all, with the appropriate tag methods.

Ah yes, as in:

bash-2.01$ lua -v
Lua 4.1 (alpha)  Copyright (C) 1994-2001 TeCGraf, PUC-Rio
bash-2.01$ cat nilcall.lua
function nil_as_func(func, ...)
  print("Nil called")
settagmethod(tag(nil), "function", nil_as_func)
bash-2.01$ lua nilcall.lua
Nil called