xo-reader: misc bugfixes + logging [wip, utests not passing]
This commit is contained in:
parent
22d4c6c601
commit
ac4ee7d6b8
14 changed files with 175 additions and 17 deletions
|
|
@ -8,8 +8,22 @@
|
|||
|
||||
namespace xo {
|
||||
namespace scm {
|
||||
const char *
|
||||
parenexprstatetype_descr(parenexprstatetype x)
|
||||
{
|
||||
switch(x) {
|
||||
case parenexprstatetype::invalid: return "invalid";
|
||||
case parenexprstatetype::lparen_0: return "lparen_0";
|
||||
case parenexprstatetype::lparen_1: return "lparen_1";
|
||||
case parenexprstatetype::n_parenexprstatetype: break;
|
||||
}
|
||||
|
||||
return "???parenexprstatetype";
|
||||
}
|
||||
|
||||
paren_xs::paren_xs()
|
||||
: parenxs_type_{parenexprstatetype::lparen_0}
|
||||
: exprstate(exprstatetype::parenexpr),
|
||||
parenxs_type_{parenexprstatetype::lparen_0}
|
||||
{}
|
||||
|
||||
std::unique_ptr<paren_xs>
|
||||
|
|
@ -221,13 +235,15 @@ namespace xo {
|
|||
void
|
||||
paren_xs::print(std::ostream & os) const {
|
||||
os << "<paren_xs"
|
||||
<< xtag("type", exs_type_);
|
||||
//<< xtag("type", exs_type_);
|
||||
<< xtag("parenxs_type", parenxs_type_);
|
||||
|
||||
if (gen_expr_)
|
||||
os << xtag("gen_expr", gen_expr_);
|
||||
|
||||
os << ">";
|
||||
}
|
||||
|
||||
|
||||
} /*namespace scm*/
|
||||
} /*namespace xo*/
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue