diff options
| author | Ginger Bill <bill@gingerbill.org> | 2018-09-04 13:47:24 +0100 |
|---|---|---|
| committer | Ginger Bill <bill@gingerbill.org> | 2018-09-04 13:47:24 +0100 |
| commit | 1d31eabb6ec3a0f7c9d62d60dc978b3805fa16bc (patch) | |
| tree | d3799063a5ff9ce587aab63a8f2bf53c0f8d7a37 /src | |
| parent | 8cd2797b2e153d780e9dec2c600ae88f92431f2e (diff) | |
Fix minor parsing issue for polymorphic identifiers
Diffstat (limited to 'src')
| -rw-r--r-- | src/parser.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/parser.cpp b/src/parser.cpp index 45a8dc3aa..6b3c07557 100644 --- a/src/parser.cpp +++ b/src/parser.cpp @@ -1370,7 +1370,7 @@ Ast *parse_ident(AstFile *f, bool allow_poly_names=false) { if (token.kind == Token_Ident) { advance_token(f); } else if (allow_poly_names && token.kind == Token_Dollar) { - Token dollar = token; + Token dollar = expect_token(f, Token_Dollar); Ast *name = ast_ident(f, expect_token(f, Token_Ident)); return ast_poly_type(f, dollar, name, nullptr); } else { |