aboutsummaryrefslogtreecommitdiff
path: root/lapi.h
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2013-04-12 15:48:47 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2013-04-12 15:48:47 -0300
commit2ca518141350667e38941eac35b76980095d2fdc (patch)
tree82595f0dfd57df5782905621298c8aae68b46389 /lapi.h
parentf5ae26ec6c2eb69f03f316e59c1e1977c52c7c23 (diff)
downloadlua-2ca518141350667e38941eac35b76980095d2fdc.tar.gz
lua-2ca518141350667e38941eac35b76980095d2fdc.tar.bz2
lua-2ca518141350667e38941eac35b76980095d2fdc.zip
Branch 5.2 - new releases for 5.2 go from here, main trunk goes
for next version
Diffstat (limited to 'lapi.h')
-rw-r--r--lapi.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/lapi.h b/lapi.h
new file mode 100644
index 00000000..0909a391
--- /dev/null
+++ b/lapi.h
@@ -0,0 +1,24 @@
1/*
2** $Id: lapi.h,v 2.7 2009/11/27 15:37:59 roberto Exp $
3** Auxiliary functions from Lua API
4** See Copyright Notice in lua.h
5*/
6
7#ifndef lapi_h
8#define lapi_h
9
10
11#include "llimits.h"
12#include "lstate.h"
13
14#define api_incr_top(L) {L->top++; api_check(L, L->top <= L->ci->top, \
15 "stack overflow");}
16
17#define adjustresults(L,nres) \
18 { if ((nres) == LUA_MULTRET && L->ci->top < L->top) L->ci->top = L->top; }
19
20#define api_checknelems(L,n) api_check(L, (n) < (L->top - L->ci->func), \
21 "not enough elements in the stack")
22
23
24#endif