diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2013-12-04 10:15:22 -0200 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2013-12-04 10:15:22 -0200 |
| commit | cac1ebd1e06f5eb1e42141f006d360ae91f1f0f3 (patch) | |
| tree | 6d3bf5302186f701e18c11ef08e42ff8bb6f08d6 /lapi.c | |
| parent | 73c5515e0080037e9c5781338922a7afaa3bdcda (diff) | |
| download | lua-cac1ebd1e06f5eb1e42141f006d360ae91f1f0f3.tar.gz lua-cac1ebd1e06f5eb1e42141f006d360ae91f1f0f3.tar.bz2 lua-cac1ebd1e06f5eb1e42141f006d360ae91f1f0f3.zip | |
detail ('ttisuserdata' renamed to 'ttisfulluserdata')
Diffstat (limited to 'lapi.c')
| -rw-r--r-- | lapi.c | 8 |
1 files changed, 4 insertions, 4 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lapi.c,v 2.189 2013/09/11 20:15:31 roberto Exp roberto $ | 2 | ** $Id: lapi.c,v 2.190 2013/09/13 16:21:52 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 | */ |
| @@ -286,7 +286,7 @@ LUA_API int lua_isstring (lua_State *L, int idx) { | |||
| 286 | 286 | ||
| 287 | LUA_API int lua_isuserdata (lua_State *L, int idx) { | 287 | LUA_API int lua_isuserdata (lua_State *L, int idx) { |
| 288 | const TValue *o = index2addr(L, idx); | 288 | const TValue *o = index2addr(L, idx); |
| 289 | return (ttisuserdata(o) || ttislightuserdata(o)); | 289 | return (ttisfulluserdata(o) || ttislightuserdata(o)); |
| 290 | } | 290 | } |
| 291 | 291 | ||
| 292 | 292 | ||
| @@ -740,7 +740,7 @@ LUA_API void lua_getuservalue (lua_State *L, int idx) { | |||
| 740 | StkId o; | 740 | StkId o; |
| 741 | lua_lock(L); | 741 | lua_lock(L); |
| 742 | o = index2addr(L, idx); | 742 | o = index2addr(L, idx); |
| 743 | api_check(L, ttisuserdata(o), "userdata expected"); | 743 | api_check(L, ttisfulluserdata(o), "full userdata expected"); |
| 744 | if (uvalue(o)->env) { | 744 | if (uvalue(o)->env) { |
| 745 | sethvalue(L, L->top, uvalue(o)->env); | 745 | sethvalue(L, L->top, uvalue(o)->env); |
| 746 | } else | 746 | } else |
| @@ -879,7 +879,7 @@ LUA_API void lua_setuservalue (lua_State *L, int idx) { | |||
| 879 | lua_lock(L); | 879 | lua_lock(L); |
| 880 | api_checknelems(L, 1); | 880 | api_checknelems(L, 1); |
| 881 | o = index2addr(L, idx); | 881 | o = index2addr(L, idx); |
| 882 | api_check(L, ttisuserdata(o), "userdata expected"); | 882 | api_check(L, ttisfulluserdata(o), "full userdata expected"); |
| 883 | if (ttisnil(L->top - 1)) | 883 | if (ttisnil(L->top - 1)) |
| 884 | uvalue(o)->env = NULL; | 884 | uvalue(o)->env = NULL; |
| 885 | else { | 885 | else { |
