lua-users home
lua-l archive

Re: New here!

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


I would suggest putting your code in a function and using pcall instead.
If the script generates an error, Lua will push the error description
on the stack and return to you.
Ryan
On 2004年7月20日 20:52:09 +0200, mark greenlancer
<markgreenlancer@aon.at> wrote:
> hello,
> 
> I use lua embedded in a c++ program.
> I compile lua with my programm and everything works fine.
> 
> But e.g. I have a syntax error lua interrupt it's work and
> returned to my programm (on dofile). I've set the 'atpanic' callback
> function - but how to get more info about the error
> (like line no., kind of error (syntax,...))?
> 
> 
> mark
>

AltStyle によって変換されたページ (->オリジナル) /