lua-users home
lua-l archive

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


> The program complains about calling nil function.
> My rough guess is that the function "test:fn" belongs to the
> table "test", and not globally known. But, I don't know how to
> correct it.
>
> Can anyone help me, please?

First get the table "test", then get the index "fn" from it. Also, since you 
declared it with a colon instead of a period, it's supposed to take a "self" 
argument, as per the manual.

Ben