]> granicus.if.org Git - clang/commit
Parse: Don't crash when 'typename' shows up in an attribute
authorDavid Majnemer <david.majnemer@gmail.com>
Sun, 28 Dec 2014 22:28:32 +0000 (22:28 +0000)
committerDavid Majnemer <david.majnemer@gmail.com>
Sun, 28 Dec 2014 22:28:32 +0000 (22:28 +0000)
commit1df588e253f5150edaad138bd887975c58ed1728
treeee3b963605e547946368fc9fe00c733ac78fd893
parent8fbf839d6c28ee53ff2eb4d59b16381c66a5a074
Parse: Don't crash when 'typename' shows up in an attribute

isDeclarationSpecifier performs error recovers which jostles the token
stream.  Specifically, TryAnnotateTypeOrScopeToken will end up consuming
a typename token which will confuse the attribute parsing machinery as
we no-longer have something identifier-like.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@224903 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Parse/ParseDecl.cpp
test/Parser/cxx-attributes.cpp
test/Parser/namespace-alias-attr.cpp