xo-reader2: + SyntaxStateMachine.forward_children method

Support gc traversal with goal of making ParserStateMachine a gc root
This commit is contained in:
Roland Conybeare 2026-03-24 17:43:45 -04:00
commit 3af72fec64
91 changed files with 626 additions and 39 deletions

View file

@ -9,7 +9,7 @@
#include "DExpectExprSsm.hpp"
#include "ssm/ISyntaxStateMachine_DDefineSsm.hpp"
#include "ssm/IPrintable_DDefineSsm.hpp"
#include <xo/expression2/detail/IPrintable_DDefineExpr.hpp>
#include <xo/expression2/DefineExpr.hpp>
#include <xo/printable2/Printable.hpp>
#include <xo/facet/FacetRegistry.hpp>
@ -689,6 +689,14 @@ namespace xo {
refrtag("expect", this->get_expect_str()),
refrtag("def_expr", expr));
}
// ----- gc support -----
void
DDefineSsm::forward_children(obj<ACollector> gc)
{
gc.forward_inplace(&def_expr_.data_);
}
} /*namespace scm*/
} /*namespace xo*/