[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: RE: Is there any easy way to copy lua functions(not c functions)
- From: "Jacob Devore" <jacob.devore@...>
- Date: Tue, 4 Jan 2005 16:37:55 -0800
Okay, so I've been hacking on this for a while and can't get it to work.
Here's the code I have so far. Do you guys see anything wrong with it?
lua_dump(src, (lua_Chunkwriter)writer, &b);
luaL_loadbuffer(dst, b.buffer, b.p - b.buffer, string);
src = the lua state I'm copying the function from
dst = the lua state I'm copying the function to
string = the name of the function from src
From: Joseph Stewart [mailto:email@example.com]
Sent: Tuesday, January 04, 2005 3:27 PM
To: Lua list
Subject: Re: Is there any easy way to copy lua functions(not c
Look at the string.dump function in the lua docs... I think this is
what you want.
On Tue, 4 Jan 2005 13:23:53 -0800, Jacob Devore
> from one environment to another?
Person who say it cannot be done should not interrupt person doing it.
-- Old Scottish Proverb