This commit is contained in:
LianaHus 2015-09-16 13:44:07 +02:00
parent ca08fe50c6
commit 1fb7488671

View File

@ -624,12 +624,8 @@ ASTPointer<Statement> Parser::parseStatement()
}
case Token::Throw:
{
ASTNodeFactory nodeFactory(*this);
ASTPointer<Expression> expression;
if (m_scanner->next() != Token::Semicolon)
BOOST_THROW_EXCEPTION(createParserError("Expected semicolon."));
statement = nodeFactory.createNode<Throw>();
statement = ASTNodeFactory(*this).createNode<Throw>();
m_scanner->next();
break;
}
case Token::Identifier: