mutable is a storage class that can follow a class/struct/union definition. Fixes PR7153

llvm-svn: 103954
This commit is contained in:
Douglas Gregor 2010-05-17 18:19:56 +00:00
parent 16f94c6e8f
commit c9a99c5e5c
2 changed files with 7 additions and 0 deletions

View File

@ -981,6 +981,7 @@ void Parser::ParseClassSpecifier(tok::TokenKind TagTokKind,
case tok::kw_typedef: // struct foo {...} typedef x;
case tok::kw_register: // struct foo {...} register x;
case tok::kw_auto: // struct foo {...} auto x;
case tok::kw_mutable: // struct foo {...} mutable x;
// As shown above, type qualifiers and storage class specifiers absolutely
// can occur after class specifiers according to the grammar. However,
// almost noone actually writes code like this. If we see one of these,

View File

@ -136,3 +136,9 @@ namespace pr6629 {
};
};
}
namespace PR7153 {
class EnclosingClass {
struct A { } mutable *member;
};
}