aboutsummaryrefslogtreecommitdiffstats
path: root/lib/LuaBridge/Tests/Lua/Lua.5.2.0/src/lapi.h
diff options
context:
space:
mode:
authorAndy Belle-Isle <drumsetmonkey@gmail.com>2019-08-28 00:57:57 -0400
committerAndy Belle-Isle <drumsetmonkey@gmail.com>2019-08-28 00:57:57 -0400
commit85fb2bff38b2ef6cb17e86c5f602ee09a365b117 (patch)
treea8066d33233ec9b6a2b9bb281a1de040ab96be7b /lib/LuaBridge/Tests/Lua/Lua.5.2.0/src/lapi.h
parent787393dd86d6c37b5680847dd4eef14406a86687 (diff)
Added LuaBridge support
Diffstat (limited to 'lib/LuaBridge/Tests/Lua/Lua.5.2.0/src/lapi.h')
-rw-r--r--lib/LuaBridge/Tests/Lua/Lua.5.2.0/src/lapi.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/lib/LuaBridge/Tests/Lua/Lua.5.2.0/src/lapi.h b/lib/LuaBridge/Tests/Lua/Lua.5.2.0/src/lapi.h
new file mode 100644
index 0000000..0909a39
--- /dev/null
+++ b/lib/LuaBridge/Tests/Lua/Lua.5.2.0/src/lapi.h
@@ -0,0 +1,24 @@
+/*
+** $Id: lapi.h,v 2.7 2009/11/27 15:37:59 roberto Exp $
+** Auxiliary functions from Lua API
+** See Copyright Notice in lua.h
+*/
+
+#ifndef lapi_h
+#define lapi_h
+
+
+#include "llimits.h"
+#include "lstate.h"
+
+#define api_incr_top(L) {L->top++; api_check(L, L->top <= L->ci->top, \
+ "stack overflow");}
+
+#define adjustresults(L,nres) \
+ { if ((nres) == LUA_MULTRET && L->ci->top < L->top) L->ci->top = L->top; }
+
+#define api_checknelems(L,n) api_check(L, (n) < (L->top - L->ci->func), \
+ "not enough elements in the stack")
+
+
+#endif