aboutsummaryrefslogtreecommitdiff
path: root/lvm.h
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2002-06-13 10:39:55 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2002-06-13 10:39:55 -0300
commit864c96f36ce8410b03652b1cb9800e4b3c76bcf7 (patch)
treed5061c0babf25cf222953e5195673534f8287f34 /lvm.h
parent0052930ffe8c86f0df7ab99dd1b6668f9e10c781 (diff)
downloadlua-864c96f36ce8410b03652b1cb9800e4b3c76bcf7.tar.gz
lua-864c96f36ce8410b03652b1cb9800e4b3c76bcf7.tar.bz2
lua-864c96f36ce8410b03652b1cb9800e4b3c76bcf7.zip
new fallback for equality `__eq'
Diffstat (limited to 'lvm.h')
-rw-r--r--lvm.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/lvm.h b/lvm.h
index 0078a617..bd1d54d7 100644
--- a/lvm.h
+++ b/lvm.h
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lvm.h,v 1.40 2002/06/03 14:08:43 roberto Exp roberto $ 2** $Id: lvm.h,v 1.41 2002/06/12 14:51:31 roberto Exp roberto $
3** Lua virtual machine 3** Lua virtual machine
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -18,8 +18,12 @@
18#define tonumber(o,n) (ttype(o) == LUA_TNUMBER || \ 18#define tonumber(o,n) (ttype(o) == LUA_TNUMBER || \
19 (((o) = luaV_tonumber(o,n)) != NULL)) 19 (((o) = luaV_tonumber(o,n)) != NULL))
20 20
21#define equalobj(L,o1,o2) \
22 (ttype(o1) == ttype(o2) && luaV_equalval(L, o1, o2))
23
21 24
22int luaV_lessthan (lua_State *L, const TObject *l, const TObject *r); 25int luaV_lessthan (lua_State *L, const TObject *l, const TObject *r);
26int luaV_equalval (lua_State *L, const TObject *t1, const TObject *t2);
23const TObject *luaV_tonumber (const TObject *obj, TObject *n); 27const TObject *luaV_tonumber (const TObject *obj, TObject *n);
24int luaV_tostring (lua_State *L, TObject *obj); 28int luaV_tostring (lua_State *L, TObject *obj);
25void luaV_gettable (lua_State *L, const TObject *t, TObject *key, StkId res); 29void luaV_gettable (lua_State *L, const TObject *t, TObject *key, StkId res);