summaryrefslogtreecommitdiffstats
path: root/clang/lib/Parse/ParseDecl.cpp
diff options
context:
space:
mode:
authorNico Weber <nicolasweber@gmx.de>2016-04-15 14:35:06 +0000
committerNico Weber <nicolasweber@gmx.de>2016-04-15 14:35:06 +0000
commit917fc9d7cb401f2de332738e4929e053f305e468 (patch)
tree85e764fdac5ea931245095a3487746aebff1d51b /clang/lib/Parse/ParseDecl.cpp
parent6cb18a09b139b231c187d4c8b9ae939460a26db8 (diff)
downloadbcm5719-llvm-917fc9d7cb401f2de332738e4929e053f305e468.tar.gz
bcm5719-llvm-917fc9d7cb401f2de332738e4929e053f305e468.zip
Revert r266415, it broke parsing SDK headers (PR27367).
llvm-svn: 266431
Diffstat (limited to 'clang/lib/Parse/ParseDecl.cpp')
-rw-r--r--clang/lib/Parse/ParseDecl.cpp15
1 files changed, 4 insertions, 11 deletions
diff --git a/clang/lib/Parse/ParseDecl.cpp b/clang/lib/Parse/ParseDecl.cpp
index b26139089fb..ebe26cfb2dd 100644
--- a/clang/lib/Parse/ParseDecl.cpp
+++ b/clang/lib/Parse/ParseDecl.cpp
@@ -609,6 +609,7 @@ void Parser::ParseMicrosoftTypeAttributes(ParsedAttributes &attrs) {
case tok::kw___ptr64:
case tok::kw___w64:
case tok::kw___ptr32:
+ case tok::kw___unaligned:
case tok::kw___sptr:
case tok::kw___uptr: {
IdentifierInfo *AttrName = Tok.getIdentifierInfo();
@@ -3086,11 +3087,6 @@ void Parser::ParseDeclarationSpecifiers(DeclSpec &DS,
break;
}
- case tok::kw___unaligned:
- isInvalid = DS.SetTypeQual(DeclSpec::TQ_unaligned, Loc, PrevSpec, DiagID,
- getLangOpts());
- break;
-
case tok::kw___sptr:
case tok::kw___uptr:
case tok::kw___ptr64:
@@ -3101,6 +3097,7 @@ void Parser::ParseDeclarationSpecifiers(DeclSpec &DS,
case tok::kw___fastcall:
case tok::kw___thiscall:
case tok::kw___vectorcall:
+ case tok::kw___unaligned:
ParseMicrosoftTypeAttributes(DS.getAttributes());
continue;
@@ -4822,10 +4819,6 @@ void Parser::ParseTypeQualifierListOpt(DeclSpec &DS, unsigned AttrReqs,
ParseOpenCLQualifiers(DS.getAttributes());
break;
- case tok::kw___unaligned:
- isInvalid = DS.SetTypeQual(DeclSpec::TQ_unaligned, Loc, PrevSpec, DiagID,
- getLangOpts());
- break;
case tok::kw___uptr:
// GNU libc headers in C mode use '__uptr' as an identifer which conflicts
// with the MS modifier keyword.
@@ -4843,6 +4836,7 @@ void Parser::ParseTypeQualifierListOpt(DeclSpec &DS, unsigned AttrReqs,
case tok::kw___fastcall:
case tok::kw___thiscall:
case tok::kw___vectorcall:
+ case tok::kw___unaligned:
if (AttrReqs & AR_DeclspecAttributesParsed) {
ParseMicrosoftTypeAttributes(DS.getAttributes());
continue;
@@ -5065,8 +5059,7 @@ void Parser::ParseDeclaratorInternal(Declarator &D,
DS.getConstSpecLoc(),
DS.getVolatileSpecLoc(),
DS.getRestrictSpecLoc(),
- DS.getAtomicSpecLoc(),
- DS.getUnalignedSpecLoc()),
+ DS.getAtomicSpecLoc()),
DS.getAttributes(),
SourceLocation());
else
OpenPOWER on IntegriCloud