detailed parser error reporting [wip - 1 example]
This commit is contained in:
parent
8c36bbce28
commit
65a83cd77c
19 changed files with 256 additions and 84 deletions
|
|
@ -466,12 +466,13 @@ namespace xo {
|
|||
|
||||
void
|
||||
exprstate::unknown_variable_error(const char * self_name,
|
||||
const token_type & tk) const
|
||||
const token_type & tk,
|
||||
parserstatemachine * p_psm) const
|
||||
{
|
||||
throw std::runtime_error
|
||||
(tostr(self_name,
|
||||
": unknown variable name",
|
||||
xtag("var", tk.text())));
|
||||
std::string errmsg = tostr("unknown variable name",
|
||||
xtag("var", tk.text()));
|
||||
|
||||
p_psm->on_error(self_name, std::move(errmsg));
|
||||
}
|
||||
} /*namespace scm*/
|
||||
} /*namespace xo*/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue