diff options
Diffstat (limited to 'lgc.c')
-rw-r--r-- | lgc.c | 14 |
1 files changed, 3 insertions, 11 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: lgc.c,v 2.119 2012/01/25 21:05:40 roberto Exp roberto $ | 2 | ** $Id: lgc.c,v 2.120 2012/05/08 13:53:33 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 | */ |
@@ -1069,9 +1069,9 @@ static void step (lua_State *L) { | |||
1069 | 1069 | ||
1070 | 1070 | ||
1071 | /* | 1071 | /* |
1072 | ** performs a basic GC step even if the collector is stopped | 1072 | ** performs a basic GC step |
1073 | */ | 1073 | */ |
1074 | void luaC_forcestep (lua_State *L) { | 1074 | void luaC_step (lua_State *L) { |
1075 | global_State *g = G(L); | 1075 | global_State *g = G(L); |
1076 | int i; | 1076 | int i; |
1077 | if (isgenerational(g)) generationalcollection(L); | 1077 | if (isgenerational(g)) generationalcollection(L); |
@@ -1082,14 +1082,6 @@ void luaC_forcestep (lua_State *L) { | |||
1082 | 1082 | ||
1083 | 1083 | ||
1084 | /* | 1084 | /* |
1085 | ** performs a basic GC step only if collector is running | ||
1086 | */ | ||
1087 | void luaC_step (lua_State *L) { | ||
1088 | if (G(L)->gcrunning) luaC_forcestep(L); | ||
1089 | } | ||
1090 | |||
1091 | |||
1092 | /* | ||
1093 | ** performs a full GC cycle; if "isemergency", does not call | 1085 | ** performs a full GC cycle; if "isemergency", does not call |
1094 | ** finalizers (which could change stack positions) | 1086 | ** finalizers (which could change stack positions) |
1095 | */ | 1087 | */ |