aboutsummaryrefslogtreecommitdiff
path: root/hash.h
diff options
context:
space:
mode:
authorThe Lua team <lua@tecgraf.puc-rio.br>1993-07-28 10:18:00 -0300
committerThe Lua team <lua@tecgraf.puc-rio.br>1993-07-28 10:18:00 -0300
commitcd05d9c5cb69020c069f037ba7f243f705d0a48a (patch)
treecb7f08c0684c10970a528984741047fb3babadd3 /hash.h
downloadlua-cd05d9c5cb69020c069f037ba7f243f705d0a48a.tar.gz
lua-cd05d9c5cb69020c069f037ba7f243f705d0a48a.tar.bz2
lua-cd05d9c5cb69020c069f037ba7f243f705d0a48a.zip
oldest known commit
Diffstat (limited to 'hash.h')
-rw-r--r--hash.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/hash.h b/hash.h
new file mode 100644
index 00000000..28c50317
--- /dev/null
+++ b/hash.h
@@ -0,0 +1,35 @@
1/*
2** hash.h
3** hash manager for lua
4** Luiz Henrique de Figueiredo - 17 Aug 90
5** Modified by Waldemar Celes Filho
6** 26 Apr 93
7*/
8
9#ifndef hash_h
10#define hash_h
11
12typedef struct node
13{
14 Object ref;
15 Object val;
16 struct node *next;
17} Node;
18
19typedef struct Hash
20{
21 char mark;
22 unsigned int nhash;
23 Node **list;
24} Hash;
25
26#define markarray(t) ((t)->mark)
27
28Hash *lua_hashcreate (unsigned int nhash);
29void lua_hashdelete (Hash *h);
30Object *lua_hashdefine (Hash *t, Object *ref);
31void lua_hashmark (Hash *h);
32
33void lua_next (void);
34
35#endif