diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2017-05-31 15:54:58 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2017-05-31 15:54:58 -0300 |
commit | 882174684147b2fbc3f3a740c463b199978d9286 (patch) | |
tree | a9811eccf6d636787c9b4170bd9dcaba3b320a53 | |
parent | 72d82a296c1430a1d2bb3fac8ed8cbfb97868707 (diff) | |
download | lua-882174684147b2fbc3f3a740c463b199978d9286.tar.gz lua-882174684147b2fbc3f3a740c463b199978d9286.tar.bz2 lua-882174684147b2fbc3f3a740c463b199978d9286.zip |
updated GC states in function 'T.gcstate'
-rw-r--r-- | ltests.c | 12 |
1 files changed, 7 insertions, 5 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: ltests.c,v 2.216 2017/04/24 18:06:12 roberto Exp roberto $ | 2 | ** $Id: ltests.c,v 2.217 2017/05/04 13:32:01 roberto Exp $ |
3 | ** Internal Module for Debugging of the Lua Implementation | 3 | ** Internal Module for Debugging of the Lua Implementation |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -734,10 +734,12 @@ static int gc_printobj (lua_State *L) { | |||
734 | 734 | ||
735 | 735 | ||
736 | static int gc_state (lua_State *L) { | 736 | static int gc_state (lua_State *L) { |
737 | static const char *statenames[] = {"propagate", "atomic", "sweepallgc", | 737 | static const char *statenames[] = { |
738 | "sweepfinobj", "sweeptobefnz", "sweepend", "pause", ""}; | 738 | "propagate", "atomic", "enteratomic", "sweepallgc", "sweepfinobj", |
739 | static const int states[] = {GCSpropagate, GCSenteratomic, GCSswpallgc, | 739 | "sweeptobefnz", "sweepend", "callfin", "pause", ""}; |
740 | GCSswpfinobj, GCSswptobefnz, GCSswpend, GCSpause, -1}; | 740 | static const int states[] = { |
741 | GCSpropagate, GCSenteratomic, GCSatomic, GCSswpallgc, GCSswpfinobj, | ||
742 | GCSswptobefnz, GCSswpend, GCScallfin, GCSpause, -1}; | ||
741 | int option = states[luaL_checkoption(L, 1, "", statenames)]; | 743 | int option = states[luaL_checkoption(L, 1, "", statenames)]; |
742 | if (option == -1) { | 744 | if (option == -1) { |
743 | lua_pushstring(L, statenames[G(L)->gcstate]); | 745 | lua_pushstring(L, statenames[G(L)->gcstate]); |