C++: Fix parsing of "Foo *foo = new Foo()"
It should be parsed as an DeclarationStatement, but instead it was parsed as an ExpressionStatement. Regression introduced with commit d3c5fff6. C++: Fix expensive parsing of expressions The introduced ASTCache did not save the correct return value of a parse* function. Because of that, the first return in Parser::parseExpressionList returned false on the second invocation (cache hit), instead of true, which resulted in an ExpressionStatement. Task-number: QTCREATORBUG-13122 Change-Id: I8dbd8852b0909edddcd3195b484f4cea92328cc5 Reviewed-by: Fawzi Mohamed <firstname.lastname@example.org>
Showing with 69 additions and 30 deletions