diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2014-05-15 17:28:39 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2014-05-15 17:28:39 -0300 |
commit | 8927c143175f02084c93a39392d2b58d3a4fb5f4 (patch) | |
tree | 2fca690d38c747524165c4aba76980b052ff4242 | |
parent | 3e977f02ac1ec62c012c5ceb8de4420285630290 (diff) | |
download | lua-8927c143175f02084c93a39392d2b58d3a4fb5f4.tar.gz lua-8927c143175f02084c93a39392d2b58d3a4fb5f4.tar.bz2 lua-8927c143175f02084c93a39392d2b58d3a4fb5f4.zip |
removed macro 'luai_checknum' (as NaN trick is not doable now)
-rw-r--r-- | lapi.c | 4 | ||||
-rw-r--r-- | lobject.h | 6 |
2 files changed, 2 insertions, 8 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lapi.c,v 2.212 2014/05/14 18:32:30 roberto Exp roberto $ | 2 | ** $Id: lapi.c,v 2.213 2014/05/15 15:22:45 roberto Exp roberto $ |
3 | ** Lua API | 3 | ** Lua API |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -499,8 +499,6 @@ LUA_API void lua_pushnil (lua_State *L) { | |||
499 | LUA_API void lua_pushnumber (lua_State *L, lua_Number n) { | 499 | LUA_API void lua_pushnumber (lua_State *L, lua_Number n) { |
500 | lua_lock(L); | 500 | lua_lock(L); |
501 | setfltvalue(L->top, n); | 501 | setfltvalue(L->top, n); |
502 | luai_checknum(L, L->top, | ||
503 | luaG_runerror(L, "C API - attempt to push a signaling NaN")); | ||
504 | api_incr_top(L); | 502 | api_incr_top(L); |
505 | lua_unlock(L); | 503 | lua_unlock(L); |
506 | } | 504 | } |
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lobject.h,v 2.89 2014/05/01 18:18:06 roberto Exp roberto $ | 2 | ** $Id: lobject.h,v 2.90 2014/05/07 11:12:51 roberto Exp roberto $ |
3 | ** Type definitions for Lua objects | 3 | ** Type definitions for Lua objects |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -269,10 +269,6 @@ typedef struct lua_TValue TValue; | |||
269 | #define setsvalue2n setsvalue | 269 | #define setsvalue2n setsvalue |
270 | 270 | ||
271 | 271 | ||
272 | /* check whether a number is valid (useful only for NaN trick) */ | ||
273 | #define luai_checknum(L,o,c) { /* empty */ } | ||
274 | |||
275 | |||
276 | 272 | ||
277 | 273 | ||
278 | /* | 274 | /* |