summaryrefslogtreecommitdiffstats
path: root/lib/Parse/ParseTentative.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Parse/ParseTentative.cpp')
-rw-r--r--lib/Parse/ParseTentative.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/Parse/ParseTentative.cpp b/lib/Parse/ParseTentative.cpp
index 18bc0ddc5b..5ce6b2b91c 100644
--- a/lib/Parse/ParseTentative.cpp
+++ b/lib/Parse/ParseTentative.cpp
@@ -485,18 +485,17 @@ Parser::isCXX11AttributeSpecifier(bool Disambiguate,
// If a keyword or an alternative token that satisfies the syntactic
// requirements of an identifier is contained in an attribute-token,
// it is considered an identifier.
- if (!Tok.getIdentifierInfo()) {
+ SourceLocation Loc;
+ if (!TryParseCXX11AttributeIdentifier(Loc)) {
IsAttribute = false;
break;
}
- ConsumeToken();
if (Tok.is(tok::coloncolon)) {
ConsumeToken();
- if (!Tok.getIdentifierInfo()) {
+ if (!TryParseCXX11AttributeIdentifier(Loc)) {
IsAttribute = false;
break;
}
- ConsumeToken();
}
// Parse the attribute-argument-clause, if present.