lua-users home
lua-l archive

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


Hi,

What do the error codes defined in lua.h correspond to?  Is this correct?

LUA_ERRSYNTAX is a syntax error
LUA_ERRFILE   is a file error
LUA_ERRMEM    is a memory error
LUA_ERRRUN    is a runtime error
LUA_ERRERR    a fatal error?

I expect the first few are fine, it's really just ERRERR that's the problem.

In the refman it says (pg 33, section 3.19), that almost any api function can result in an error. Are the returned error codes taken from those above? Also, lua.h says the error codes are for lua_pcall and lua_load (it implies only them), but the refman says they can't return error codes. What am I missing?


Thanks for your time,
Chris