some reorganization in 'lobject.h'

(just moving stuff around)
This commit is contained in:
Roberto Ierusalimschy
2018-02-22 14:28:10 -03:00
parent c72ac048b9
commit 477ca2fe8c
2 changed files with 232 additions and 196 deletions

7
lgc.c
View File

@@ -1,5 +1,5 @@
/*
** $Id: lgc.c,v 2.248 2018/02/19 16:02:25 roberto Exp roberto $
** $Id: lgc.c,v 2.248 2018/02/20 16:52:50 roberto Exp roberto $
** Garbage Collector
** See Copyright Notice in lua.h
*/
@@ -79,6 +79,11 @@
#define checkconsistency(obj) \
lua_longassert(!iscollectable(obj) || righttt(obj))
/*
** Protected access to objects in values
*/
#define gcvalueN(o) (iscollectable(o) ? gcvalue(o) : NULL)
#define markvalue(g,o) { checkconsistency(o); \
if (valiswhite(o)) reallymarkobject(g,gcvalue(o)); }