lua-users home
lua-l archive

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


--- El vie 30-sep-11, Sebastien Lai <237482@googlemail.com> escribió:

> De: Sebastien Lai <237482@googlemail.com>
> Asunto: Re: How to avoid global variables in a lua module (using C api)
> Para: "Lua mailing list" <lua-l@lists.lua.org>
> Fecha: viernes, 30 de septiembre de 2011, 16:41
> You have two choices here:
> 
> Store your values in the Lua registry (as Ezequiel said),

Why would I choose Lua registry over upvalues ?

Besides, I would like to know: is there any difference
in declaring C static variables vs. using the Lua registry?

Thanks,
Ezequiel.