diff --git a/parse.c b/parse.c index 3ef378d..a88226c 100644 --- a/parse.c +++ b/parse.c @@ -886,6 +886,11 @@ static void toplevel() { char *name = ident(); + lvars = new_vec(); + breaks = new_vec(); + continues = new_vec(); + switches = new_vec(); + // Function if (consume('(')) { Vector *params = new_vec(); @@ -898,11 +903,6 @@ static void toplevel() { Token *t = tokens->data[pos]; Node *node = new_node(ND_DECL, t); - lvars = new_vec(); - breaks = new_vec(); - continues = new_vec(); - switches = new_vec(); - node->name = name; node->params = params;