fixed top level union definition
This commit is contained in:
parent
9d6498637f
commit
3ed0922c63
1 changed files with 1 additions and 1 deletions
2
parser.c
2
parser.c
|
|
@ -1282,7 +1282,7 @@ static void parse(parser *p)
|
|||
ast_node *expr = parse_statement(p);
|
||||
while (expr) {
|
||||
if (expr->type != NODE_FUNCTION && expr->type != NODE_VAR_DECL && expr->type != NODE_IMPORT &&
|
||||
expr->type != NODE_STRUCT && expr->type != NODE_ENUM && expr->type != NODE_ENUM) {
|
||||
expr->type != NODE_STRUCT && expr->type != NODE_UNION && expr->type != NODE_ENUM) {
|
||||
error(p, "expected function, struct, enum, union, global variable or import statement.");
|
||||
return;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue