CPlusPlus: fixed parsing function-try-catch with ctor-initializer

C++ standard defines that 'try' should be before optional ctor
initializer, so wrong order changed. Added documentation to
parseTryBlockStatement and new test.

Task-number: QTCREATORBUG-9064
Change-Id: Id19cdc53c034cb1232ae27e0bfe36d85b7ad0452
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
This commit is contained in:
Sergey Shambir
2013-04-03 23:33:44 +04:00
committed by Erik Verbruggen
parent f7de8c934a
commit 2ead48fb26
3 changed files with 96 additions and 35 deletions

View File

@@ -165,7 +165,7 @@ public:
bool parseTemplateParameter(DeclarationAST *&node);
bool parseTemplateParameterList(DeclarationListAST *&node);
bool parseThrowExpression(ExpressionAST *&node);
bool parseTryBlockStatement(StatementAST *&node);
bool parseTryBlockStatement(StatementAST *&node, CtorInitializerAST **placeholder);
bool parseCatchClause(CatchClauseListAST *&node);
bool parseTypeId(ExpressionAST *&node);
bool parseTypeIdList(ExpressionListAST *&node);