aboutsummaryrefslogtreecommitdiff
path: root/lapi.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2000-08-29 17:43:28 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2000-08-29 17:43:28 -0300
commita97f29f15487c5f584185f646f9cfc06a04b26ca (patch)
treee7ffd959fb80f9622d74a2efadfd7880037d64ca /lapi.c
parent4135f4f5862b57d9dbf3e9b7c6507f5c86516327 (diff)
downloadlua-a97f29f15487c5f584185f646f9cfc06a04b26ca.tar.gz
lua-a97f29f15487c5f584185f646f9cfc06a04b26ca.tar.bz2
lua-a97f29f15487c5f584185f646f9cfc06a04b26ca.zip
explicit stack control in the API
Diffstat (limited to 'lapi.c')
-rw-r--r--lapi.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/lapi.c b/lapi.c
index 5a000b49..e3d4a906 100644
--- a/lapi.c
+++ b/lapi.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lapi.c,v 1.88 2000/08/28 17:57:04 roberto Exp roberto $ 2** $Id: lapi.c,v 1.89 2000/08/29 14:52:27 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*/
@@ -45,6 +45,10 @@ void luaA_pushobject (lua_State *L, const TObject *o) {
45 incr_top; 45 incr_top;
46} 46}
47 47
48int lua_stackspace (lua_State *L) {
49 return (L->stack_last - L->top);
50}
51
48 52
49 53
50/* 54/*