diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2002-11-07 13:37:10 -0200 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2002-11-07 13:37:10 -0200 |
| commit | dff9be4224a1cd0f338b544b9e01d42f0f4e537f (patch) | |
| tree | 1dc8846da882dd37d9f420c10ea545ce92fb3b8a /ldebug.c | |
| parent | 118347d8c3b83ea0291918e81c5367937316fabb (diff) | |
| download | lua-dff9be4224a1cd0f338b544b9e01d42f0f4e537f.tar.gz lua-dff9be4224a1cd0f338b544b9e01d42f0f4e537f.tar.bz2 lua-dff9be4224a1cd0f338b544b9e01d42f0f4e537f.zip | |
new macros to distinguish different types of object moves (for future GC
evolution).
Diffstat (limited to 'ldebug.c')
| -rw-r--r-- | ldebug.c | 10 |
1 files changed, 5 insertions, 5 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: ldebug.c,v 1.134 2002/09/05 19:45:42 roberto Exp roberto $ | 2 | ** $Id: ldebug.c,v 1.135 2002/10/16 20:40:58 roberto Exp roberto $ |
| 3 | ** Debug Interface | 3 | ** Debug Interface |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -127,7 +127,7 @@ LUA_API const char *lua_setlocal (lua_State *L, const lua_Debug *ar, int n) { | |||
| 127 | if (!name || name[0] == '(') /* `(' starts private locals */ | 127 | if (!name || name[0] == '(') /* `(' starts private locals */ |
| 128 | name = NULL; | 128 | name = NULL; |
| 129 | else | 129 | else |
| 130 | setobj(ci->base+(n-1), L->top); | 130 | setobjs2s(ci->base+(n-1), L->top); |
| 131 | } | 131 | } |
| 132 | lua_unlock(L); | 132 | lua_unlock(L); |
| 133 | return name; | 133 | return name; |
| @@ -218,7 +218,7 @@ LUA_API int lua_getinfo (lua_State *L, const char *what, lua_Debug *ar) { | |||
| 218 | break; | 218 | break; |
| 219 | } | 219 | } |
| 220 | case 'f': { | 220 | case 'f': { |
| 221 | setobj(L->top, f); | 221 | setobj2s(L->top, f); |
| 222 | status = 2; | 222 | status = 2; |
| 223 | break; | 223 | break; |
| 224 | } | 224 | } |
| @@ -538,8 +538,8 @@ void luaG_errormsg (lua_State *L) { | |||
| 538 | if (L->errfunc != 0) { /* is there an error handling function? */ | 538 | if (L->errfunc != 0) { /* is there an error handling function? */ |
| 539 | StkId errfunc = restorestack(L, L->errfunc); | 539 | StkId errfunc = restorestack(L, L->errfunc); |
| 540 | if (!ttisfunction(errfunc)) luaD_throw(L, LUA_ERRERR); | 540 | if (!ttisfunction(errfunc)) luaD_throw(L, LUA_ERRERR); |
| 541 | setobj(L->top, L->top - 1); /* move argument */ | 541 | setobjs2s(L->top, L->top - 1); /* move argument */ |
| 542 | setobj(L->top - 1, errfunc); /* push function */ | 542 | setobjs2s(L->top - 1, errfunc); /* push function */ |
| 543 | incr_top(L); | 543 | incr_top(L); |
| 544 | luaD_call(L, L->top - 2, 1); /* call it */ | 544 | luaD_call(L, L->top - 2, 1); /* call it */ |
| 545 | } | 545 | } |
