aboutsummaryrefslogtreecommitdiff
path: root/lgc.c
diff options
context:
space:
mode:
authorRoberto Ierusalimschy <roberto@inf.puc-rio.br>1999-02-26 12:48:55 -0300
committerRoberto Ierusalimschy <roberto@inf.puc-rio.br>1999-02-26 12:48:55 -0300
commit72d675aba78d59e22ebfadbe447f4f51ddab5a5c (patch)
tree2f43006cba58bcfc97f01ecdd6f00e35e92aa673 /lgc.c
parentba57f7d946bc0b600996f7a982b2fb644df76a98 (diff)
downloadlua-72d675aba78d59e22ebfadbe447f4f51ddab5a5c.tar.gz
lua-72d675aba78d59e22ebfadbe447f4f51ddab5a5c.tar.bz2
lua-72d675aba78d59e22ebfadbe447f4f51ddab5a5c.zip
macros "growvector" and "reallocvector" more compact
Diffstat (limited to 'lgc.c')
-rw-r--r--lgc.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/lgc.c b/lgc.c
index dca1bb98..b321e76c 100644
--- a/lgc.c
+++ b/lgc.c
@@ -1,5 +1,5 @@
1/* 1/*
2** $Id: lgc.c,v 1.20 1999/01/22 18:08:03 roberto Exp roberto $ 2** $Id: lgc.c,v 1.21 1999/02/25 15:16:26 roberto Exp roberto $
3** Garbage Collector 3** Garbage Collector
4** See Copyright Notice in lua.h 4** See Copyright Notice in lua.h
5*/ 5*/
@@ -38,8 +38,7 @@ int luaC_ref (TObject *o, int lock) {
38 if (L->refArray[ref].status == FREE) 38 if (L->refArray[ref].status == FREE)
39 break; 39 break;
40 if (ref == L->refSize) { /* no more empty spaces? */ 40 if (ref == L->refSize) { /* no more empty spaces? */
41 L->refArray = luaM_growvector(L->refArray, L->refSize, 1, struct ref, 41 luaM_growvector(L->refArray, L->refSize, 1, struct ref, refEM, MAX_INT);
42 refEM, MAX_INT);
43 L->refSize++; 42 L->refSize++;
44 } 43 }
45 L->refArray[ref].o = *o; 44 L->refArray[ref].o = *o;