parser->function = func;
if (!parse_block_into(parser, block, true)) {
ast_block_delete(block);
- goto enderrfn;
+ goto enderrfn2;
}
if (!ast_function_blocks_add(func, block)) {
ast_block_delete(block);
- goto enderrfn;
+ goto enderrfn2;
}
parser->function = old;
parseerror(parser, "missing semicolon after function body (mandatory with -std=qcc)");
return retval;
+enderrfn2:
+ parser->functions_count--;
enderrfn:
ast_function_delete(func);
var->constval.vfunc = NULL;