aboutsummaryrefslogtreecommitdiff
path: root/ltable.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>2006-09-11 11:07:24 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>2006-09-11 11:07:24 -0300
commita7c9e45c64a4bff9bdaf0d1177509bdd00fc53f7 (patch)
treef452f26770539293979a3dbd752ee0b38b849123 /ltable.c
parentcedd2092ebe402e0c6d600969ec926496a8a9d22 (diff)
downloadlua-a7c9e45c64a4bff9bdaf0d1177509bdd00fc53f7.tar.gz
lua-a7c9e45c64a4bff9bdaf0d1177509bdd00fc53f7.tar.bz2
lua-a7c9e45c64a4bff9bdaf0d1177509bdd00fc53f7.zip
avoid trailing white spaces
Diffstat (limited to 'ltable.c')
-rw-r--r--ltable.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/ltable.c b/ltable.c
index a29eb030..722e1de3 100644
--- a/ltable.c
+++ b/ltable.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: ltable.c,v 2.33 2006/07/11 15:53:29 roberto Exp roberto $ 2** $Id: ltable.c,v 2.34 2006/08/07 19:14:30 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*/
@@ -48,7 +48,7 @@
48 48
49 49
50#define hashpow2(t,n) (gnode(t, lmod((n), sizenode(t)))) 50#define hashpow2(t,n) (gnode(t, lmod((n), sizenode(t))))
51 51
52#define hashstr(t,str) hashpow2(t, (str)->tsv.hash) 52#define hashstr(t,str) hashpow2(t, (str)->tsv.hash)
53#define hashboolean(t,p) hashpow2(t, p) 53#define hashboolean(t,p) hashpow2(t, p)
54 54
@@ -302,7 +302,7 @@ void luaH_resize (lua_State *L, Table *t, int nasize, int nhsize) {
302 if (nasize > oldasize) /* array part must grow? */ 302 if (nasize > oldasize) /* array part must grow? */
303 setarrayvector(L, t, nasize); 303 setarrayvector(L, t, nasize);
304 /* create new hash part with appropriate size */ 304 /* create new hash part with appropriate size */
305 setnodevector(L, t, nhsize); 305 setnodevector(L, t, nhsize);
306 if (nasize < oldasize) { /* array part must shrink? */ 306 if (nasize < oldasize) { /* array part must shrink? */
307 t->sizearray = nasize; 307 t->sizearray = nasize;
308 /* re-insert elements from vanishing slice */ 308 /* re-insert elements from vanishing slice */
@@ -386,11 +386,11 @@ static Node *getfreepos (Table *t) {
386 386
387 387
388/* 388/*
389** inserts a new key into a hash table; first, check whether key's main 389** inserts a new key into a hash table; first, check whether key's main
390** position is free. If not, check whether colliding node is in its main 390** position is free. If not, check whether colliding node is in its main
391** position or not: if it is not, move colliding node to an empty place and 391** position or not: if it is not, move colliding node to an empty place and
392** put new key in its main position; otherwise (colliding node is in its main 392** put new key in its main position; otherwise (colliding node is in its main
393** position), new key goes to an empty position. 393** position), new key goes to an empty position.
394*/ 394*/
395static TValue *newkey (lua_State *L, Table *t, const TValue *key) { 395static TValue *newkey (lua_State *L, Table *t, const TValue *key) {
396 Node *mp = mainposition(t, key); 396 Node *mp = mainposition(t, key);