summaryrefslogtreecommitdiff
path: root/src/lvm.h
diff options
context:
space:
mode:
authorLua Team <team@lua.org>2014-07-31 12:00:00 +0000
committerrepogen <>2014-07-31 12:00:00 +0000
commitd7648e85b78d53a2248de909868192598ad0eb69 (patch)
treec67708a14fd29f8ff7e4981aadb041c5ab577e08 /src/lvm.h
parent3907bda05b0e73eba86487ad703e832ca14b64ce (diff)
downloadlua-github-5.3.0-alpha.tar.gz
Lua 5.3.0-alpha5.3.0-alpha
Diffstat (limited to 'src/lvm.h')
-rw-r--r--src/lvm.h17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/lvm.h b/src/lvm.h
index 36e78e68..0f4667af 100644
--- a/src/lvm.h
+++ b/src/lvm.h
@@ -1,5 +1,5 @@
/*
-** $Id: lvm.h,v 2.31 2014/05/26 17:10:22 roberto Exp $
+** $Id: lvm.h,v 2.33 2014/07/30 14:42:44 roberto Exp $
** Lua virtual machine
** See Copyright Notice in lua.h
*/
@@ -13,6 +13,20 @@
#include "ltm.h"
+#if !defined(LUA_NOCVTN2S)
+#define cvt2str(o) ttisnumber(o)
+#else
+#define cvt2str(o) 0 /* no convertion from numbers to strings */
+#endif
+
+
+#if !defined(LUA_NOCVTS2N)
+#define cvt2num(o) ttisstring(o)
+#else
+#define cvt2num(o) 0 /* no convertion from strings to numbers */
+#endif
+
+
#define tonumber(o,n) \
(ttisfloat(o) ? (*(n) = fltvalue(o), 1) : luaV_tonumber_(o,n))
@@ -29,7 +43,6 @@ LUAI_FUNC int luaV_lessthan (lua_State *L, const TValue *l, const TValue *r);
LUAI_FUNC int luaV_lessequal (lua_State *L, const TValue *l, const TValue *r);
LUAI_FUNC int luaV_tonumber_ (const TValue *obj, lua_Number *n);
LUAI_FUNC int luaV_tointeger_ (const TValue *obj, lua_Integer *p);
-LUAI_FUNC int luaV_tostring (lua_State *L, StkId obj);
LUAI_FUNC void luaV_gettable (lua_State *L, const TValue *t, TValue *key,
StkId val);
LUAI_FUNC void luaV_settable (lua_State *L, const TValue *t, TValue *key,