Skip to content

Commit 3455c95

Browse files
committed
fix(parser)
1 parent 68764fc commit 3455c95

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

argon/lang/parser2/parser2.cpp

+2
Original file line numberDiff line numberDiff line change
@@ -1213,6 +1213,8 @@ Node *Parser::ParseSyncBlock(Context *context) {
12131213
this->Eat(true);
12141214

12151215
expr = (ArObject *) this->ParseExpression(context, PeekPrecedence(TokenType::ASTERISK));
1216+
if (!expr)
1217+
throw ParserException(this->tkcur_.loc, kStandardError[0]);
12161218

12171219
if (((Node *) expr.Get())->node_type == NodeType::LITERAL)
12181220
throw ParserException(((Node *) expr.Get())->loc, kStandardError[14]);

0 commit comments

Comments
 (0)