aboutsummaryrefslogtreecommitdiff
path: root/ltable.h
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2005-01-05 16:20:51 -0200
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2005-01-05 16:20:51 -0200
commite2498e079e4636217e89f0b28844c4b5df4f8793 (patch)
treeda82e007f0e8153985323c2bdb190811f79e0c57 /ltable.h
parent65726f3e2e226f6a350a5dba643c13c8edd34965 (diff)
downloadlua-e2498e079e4636217e89f0b28844c4b5df4f8793.tar.gz
lua-e2498e079e4636217e89f0b28844c4b5df4f8793.tar.bz2
lua-e2498e079e4636217e89f0b28844c4b5df4f8793.zip
change in hash algorithm so that it does not need empty slot
(tables can be 100% full)
Diffstat (limited to 'ltable.h')
-rw-r--r--ltable.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/ltable.h b/ltable.h
index 3927f088..d8ba8c8a 100644
--- a/ltable.h
+++ b/ltable.h
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltable.h,v 2.3 2004/10/06 18:34:16 roberto Exp roberto $ 2** $Id: ltable.h,v 2.4 2005/01/04 15:55:12 roberto Exp roberto $
3** Lua tables (hash) 3** Lua tables (hash)
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -18,6 +18,8 @@
18#define key2tval(n) (cast(const TValue *, gkey(n))) 18#define key2tval(n) (cast(const TValue *, gkey(n)))
19 19
20 20
21extern const Node luaH_dummynode;
22
21const TValue *luaH_getnum (Table *t, int key); 23const TValue *luaH_getnum (Table *t, int key);
22TValue *luaH_setnum (lua_State *L, Table *t, int key); 24TValue *luaH_setnum (lua_State *L, Table *t, int key);
23const TValue *luaH_getstr (Table *t, TString *key); 25const TValue *luaH_getstr (Table *t, TString *key);