forked from OSchip/llvm-project
cfaa4cdc35
The first part of that line doesn't parse correctly and ParseClassSpecifier() for some reason skips to tok::comma to recover, and then ParseDeclarationSpecifiers() sees the next struct and calls ParseClassSpecifier() again with the same DeclSpec object. However, the first call already called ActOnCXXGlobalScopeSpecifier() on the DeclSpec's CXXScopeSpec, and sema gets confused when this gets called again. As a fix, let ParseClassSpecifier() (and ParseEnumSpecifier()) call ParseOptionalCXXScopeSpec() with a temporary CXXScopeSpec object, and only copy it into the DeclSpec if things work out. (This is also how all the other functions that set the DeclSpec's TypeSpecScope set it.) Found by SLi's bot. llvm-svn: 229288 |
||
---|---|---|
.. | ||
CMakeLists.txt | ||
Makefile | ||
ParseAST.cpp | ||
ParseCXXInlineMethods.cpp | ||
ParseDecl.cpp | ||
ParseDeclCXX.cpp | ||
ParseExpr.cpp | ||
ParseExprCXX.cpp | ||
ParseInit.cpp | ||
ParseObjc.cpp | ||
ParseOpenMP.cpp | ||
ParsePragma.cpp | ||
ParseStmt.cpp | ||
ParseStmtAsm.cpp | ||
ParseTemplate.cpp | ||
ParseTentative.cpp | ||
Parser.cpp | ||
RAIIObjectsForParser.h |