xo-reader2 stack: + op<= setup

This commit is contained in:
Roland Conybeare 2026-03-12 21:00:16 -05:00
commit 8fda8c8f14
2 changed files with 18 additions and 0 deletions

View file

@ -144,6 +144,12 @@ namespace xo {
assert(name);
this->cmplt_binding_ = global_symtab_->lookup_binding(name);
}
{
const DUniqueString * name = stringtable_.lookup("_cmple");
assert(name);
this->cmple_binding_ = global_symtab_->lookup_binding(name);
}
}
ParserStateMachine::~ParserStateMachine()
@ -220,6 +226,15 @@ namespace xo {
return retval;
}
obj<AGCObject>
ParserStateMachine::cmple_pm() const
{
obj<AGCObject> retval = global_env_->lookup_value(cmple_binding_);
assert(retval);
return retval;
}
bool
ParserStateMachine::is_at_toplevel() const noexcept
{