[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Passing C struct values automatically to Lua
- From: steve donovan <steve.j.donovan@...>
- Date: Fri, 6 Nov 2009 15:06:35 +0200
On Fri, Nov 6, 2009 at 2:59 PM, zweifel <email@example.com> wrote:
> I checked the arg variable and it is nil. I am reading things about
> debug.getinfo now, but I found nothing about anonymous calls...
Ah right, sorry I was thinking about scripts running from Lua itself.
Why not set a global to the name of the script before you launch it
with lua_pcall? Or pass it as an argument?
(I'm thinking of how require() works; it passes the name of the
module, so that a module can be defined as
That is, it picks up the name from the first argument)