mirror of https://github.com/rusefi/lua.git
details
This commit is contained in:
parent
b518d14071
commit
5bb5a1831d
10
ltable.c
10
ltable.c
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
** $Id: ltable.c,v 1.128 2003/02/20 20:12:39 roberto Exp roberto $
|
** $Id: ltable.c,v 1.129 2003/03/18 12:50:04 roberto Exp roberto $
|
||||||
** Lua tables (hash)
|
** Lua tables (hash)
|
||||||
** See Copyright Notice in lua.h
|
** See Copyright Notice in lua.h
|
||||||
*/
|
*/
|
||||||
|
@ -54,11 +54,11 @@
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#define hashg(t,n) (gnode(t, lmod((n), sizenode(t))))
|
||||||
|
|
||||||
#define hashnum(t,n) \
|
#define hashnum(t,n) hashg(t, cast(lu_hash, cast(ls_hash, (n))))
|
||||||
(gnode(t, lmod(cast(lu_hash, cast(ls_hash, n)), sizenode(t))))
|
#define hashstr(t,str) hashg(t, (str)->tsv.hash)
|
||||||
#define hashstr(t,str) (gnode(t, lmod((str)->tsv.hash, sizenode(t))))
|
#define hashboolean(t,p) hashg(t, p)
|
||||||
#define hashboolean(t,p) (gnode(t, lmod(p, sizenode(t))))
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
** avoid modulus by power of 2 for pointers, as they tend to have many
|
** avoid modulus by power of 2 for pointers, as they tend to have many
|
||||||
|
|
Loading…
Reference in New Issue