Refactor block_t storage in parser_t from a linked list to a vector

This commit is contained in:
ridiculousfish
2013-12-20 17:41:21 -08:00
parent 12be83562d
commit e38217683c
7 changed files with 218 additions and 187 deletions

View File

@@ -580,7 +580,8 @@ static void exec_no_exec(parser_t &parser, const job_t *job)
}
else if (builtin_name == L"end")
{
if (parser.current_block == NULL || parser.current_block->type() == TOP)
const block_t *block = parser.current_block();
if (block == NULL || block->type() == TOP)
{
fprintf(stderr, "Warning: not popping the root block\n");
}