zig

fork of https://codeberg.org/ziglang/zig
Log | Files | Refs | README | LICENSE

commit 773cd851fe83d1ee89d7e0ca9e7ad7327d2962c9 (tree)
parent 105317285402befe75289c20c4b12fccbe94aa08
Author: Andrew Kelley <superjoe30@gmail.com>
Date:   Sun, 31 Jan 2016 17:17:00 -0700

parser: fix parsing of type decls

Diffstat:
Msrc/parser.cpp | 2++
1 file changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/parser.cpp b/src/parser.cpp @@ -2508,6 +2508,8 @@ static AstNode *ast_parse_type_decl(ParseContext *pc, int *token_index, ast_buf_from_token(pc, name_tok, &node->data.type_decl.symbol); node->data.type_decl.child_type = ast_parse_prefix_op_expr(pc, token_index, true); + ast_eat_token(pc, token_index, TokenIdSemicolon); + node->data.type_decl.visib_mod = visib_mod; node->data.type_decl.directives = directives;