1
0
forked from GitHub/gf-core

detect an attempt to linearize tree with partial application

This commit is contained in:
krangelov
2021-12-08 19:32:53 +01:00
parent 3f8642d0b9
commit a7686cddde

View File

@@ -23,9 +23,11 @@ void PgfLinearizer::TreeNode::linearize_arg(PgfLinearizationOutputIface *out, Pg
while (d > 0) {
arg = arg->next_arg;
if (arg == 0)
throw pgf_error("Found inconsistency in the PMCFG representation");
break;
d--;
}
if (arg == 0)
throw pgf_error("Missing argument");
size_t lindex = eval_param(r);
arg->linearize(out, linearizer, lindex);
}