diff options
| -rw-r--r-- | llimits.h | 10 |
1 files changed, 7 insertions, 3 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: llimits.h,v 1.88 2011/02/28 17:32:10 roberto Exp roberto $ | 2 | ** $Id: llimits.h,v 1.89 2011/05/05 19:43:14 roberto Exp roberto $ |
| 3 | ** Limits, basic types, and some other `installation-dependent' definitions | 3 | ** Limits, basic types, and some other `installation-dependent' definitions |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -70,13 +70,17 @@ typedef LUAI_UACNUMBER l_uacNumber; | |||
| 70 | /* | 70 | /* |
| 71 | ** assertion for checking API calls | 71 | ** assertion for checking API calls |
| 72 | */ | 72 | */ |
| 73 | #if !defined(luai_apicheck) | ||
| 74 | |||
| 73 | #if defined(LUA_USE_APICHECK) | 75 | #if defined(LUA_USE_APICHECK) |
| 74 | #include <assert.h> | 76 | #include <assert.h> |
| 75 | #define luai_apicheck(L,e) { (void)L; assert(e); } | 77 | #define luai_apicheck(L,e) assert(e) |
| 76 | #elif !defined(luai_apicheck) | 78 | #else |
| 77 | #define luai_apicheck(L,e) lua_assert(e) | 79 | #define luai_apicheck(L,e) lua_assert(e) |
| 78 | #endif | 80 | #endif |
| 79 | 81 | ||
| 82 | #endif | ||
| 83 | |||
| 80 | #define api_check(l,e,msg) luai_apicheck(l,(e) && msg) | 84 | #define api_check(l,e,msg) luai_apicheck(l,(e) && msg) |
| 81 | 85 | ||
| 82 | 86 | ||
