[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: rename LUA_RIDX_CPCALL to LUA_RIDX_CCALL? (5.2.0-work2)
- From: Roberto Ierusalimschy <roberto@...>
- Date: Mon, 29 Mar 2010 11:22:58 -0300
> and in this case you can't even easily use (5.1) lua_cpcall:
>
> static int
> actually_push_string(lua_State *L)
> {
> /* Wait a minute, there's no good way to get the string back
> if the return values go away. */
> lua_pushstring(L, (char const *)lua_touserdata(L, 1));
> return 1;
> }
In 5.2, luaL_cpcall is able to return values. Doesn't that solve
the problem? (luaL_cpcall is also cheaper than 5.1's lua_cpcall.)
-- Roberto