lua-users home
lua-l archive

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


> You could add
> 
>         msg = lua_tostring(L, -1);
>         if (msg)
>           luaL_traceback(L, L, msg, 1);
> 
> after the `lua_pushliteral` call in `msghandler`. (I'd prefer it
> that `msghandler` leaves all to-string conversions to the `report`
> function, though.)

When 'report' is called, there is no stack left to do a traceback.

-- Roberto