diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2005-09-09 15:24:42 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2005-09-09 15:24:42 -0300 |
commit | 7fbbf1adc606fdea2432809a7133389f0db3c9c5 (patch) | |
tree | 80f3df68a059e9aa872f5d330387288c090e9877 | |
parent | 6dd3a73ca2b57b264dc1ad20e183f0efd1b9484d (diff) | |
download | lua-github-v5.1-alpha.tar.gz |
explicit macro to control use of _longjmpv5_1_Alphav5.1-alpha
-rw-r--r-- | luaconf.h | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -1,5 +1,5 @@ /* -** $Id: luaconf.h,v 1.63 2005/09/02 19:53:25 roberto Exp roberto $ +** $Id: luaconf.h,v 1.64 2005/09/06 17:21:03 roberto Exp roberto $ ** Configuration file for Lua ** See Copyright Notice in lua.h */ @@ -235,7 +235,7 @@ ** CHANGE them if you want to improve this functionality (e.g., by using ** GNU readline and history facilities). */ -#if !defined(LUA_ANSI) && defined(LUA_USE_READLINE) +#if defined(LUA_USE_READLINE) #include <stdio.h> #include <readline/readline.h> #include <readline/history.h> @@ -554,8 +554,8 @@ union luai_Cast { double l_d; long l_l; }; ** CHANGE them if you prefer to use longjmp/setjmp even with C++ ** or if want/don't to use _longjmp/_setjmp instead of regular ** longjmp/setjmp. By default, Lua handles errors with exceptions when -** compiling as C++ code, with _longjmp/_setjmp when compiling as C code -** in some Unix systems, and with longjmp/setjmp otherwise. +** compiling as C++ code, with _longjmp/_setjmp when asked to use them, +** and with longjmp/setjmp otherwise. */ #if defined(__cplusplus) /* C++ exceptions */ @@ -564,7 +564,7 @@ union luai_Cast { double l_d; long l_l; }; { if ((c)->status == 0) (c)->status = -1; } #define luai_jmpbuf int /* dummy variable */ -#elif !defined(LUA_ANSI) && (defined(__GLIBC__)) +#elif defined(LUA_USE_ULONGJMP) /* in Unix, try _longjmp/_setjmp (more efficient) */ #define LUAI_THROW(L,c) _longjmp((c)->b, 1) #define LUAI_TRY(L,c,a) if (_setjmp((c)->b) == 0) { a } |