[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: lua_dofile and _ALERT, 5.0a compatibility
- From: Eero Pajarre <epajarre@...>
- Date: Fri, 01 Nov 2002 10:27:05 +0200
I just changed my application from Lua 4.? to Lua 5.0a
(I am planning to add Lua related stuff which would
depend on the new features)
I noticed following difference between the 4 and 5-versions:
In previous version lua_dofile returned an error code if
it could not parse the file. In 5.0a it exits my program.
The reason for the exit seems to be in lauxlib.c callalert,
which attempts to lua_call "_ALERT", which is not defined and
Lua ends panicking. The 4.0 version seems to ignore _ALERT if
it does not exist.
I think I have a good idea how to avoid this in my case,
but maybe version compatibility should/could be improved here.
(I tried to check the mailing list archives, and did not
find this mentioned there)