[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: AW: How to get Lua functions address?
- From: Luiz Henrique de Figueiredo <lhf@...>
- Date: Tue, 7 Jan 2003 11:51:13 -0200
>An other thing is that I would recommend using lua_pcall instead of lua_call.
lua_pcall is meant for when you must handle the error, for instance, by
showing a error message. lua_call is by far the most useful function; errors
that happen inside a lua_call will be automatically propagated back to the
last lua_pcall that was called before lua_call, typically the one that
initiated the whole process. This is almost always what you want and allows
for much cleaner programming. That's how the standalone interpreter works.
--lhf