Parser fix: Consume break and continue.

This commit is contained in:
Christian 2014-10-29 12:59:06 +01:00
parent 95c973cc12
commit 2939b180ba

View File

@ -266,9 +266,11 @@ ASTPointer<Statement> Parser::parseStatement()
// starting from here, all statements must be terminated by a semicolon
case Token::CONTINUE:
statement = ASTNodeFactory(*this).createNode<Continue>();
m_scanner->next();
break;
case Token::BREAK:
statement = ASTNodeFactory(*this).createNode<Break>();
m_scanner->next();
break;
case Token::RETURN:
{