diff options
author | John McCall <rjmccall@apple.com> | 2009-08-29 03:50:18 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2009-08-29 03:50:18 +0000 |
commit | 5fee110ac106370f75592df024001de73edced2a (patch) | |
tree | 1a7a5bdb754317fc71f59ca6cd3162bf1a40410f /lib/AST/DeclBase.cpp | |
parent | 2a29c4b6ef710de49b1fd72902d6930033edae24 (diff) |
For consistency, just make friend declarations AS_public.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@80420 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/DeclBase.cpp')
-rw-r--r-- | lib/AST/DeclBase.cpp | 12 |
1 files changed, 2 insertions, 10 deletions
diff --git a/lib/AST/DeclBase.cpp b/lib/AST/DeclBase.cpp index 5d30795abd..3ced0eff4c 100644 --- a/lib/AST/DeclBase.cpp +++ b/lib/AST/DeclBase.cpp @@ -379,16 +379,8 @@ SourceLocation Decl::getBodyRBrace() const { #ifndef NDEBUG void Decl::CheckAccessDeclContext() const { - if (isa<TranslationUnitDecl>(this) || - !isa<CXXRecordDecl>(getDeclContext())) - return; - - // FIXME: Should friend declarations have access specifiers? - if (isa<FriendDecl>(this) || - getFriendObjectKind() != FOK_None) - return; - - assert(Access != AS_none && + assert((Access != AS_none || isa<TranslationUnitDecl>(this) || + !isa<CXXRecordDecl>(getDeclContext())) && "Access specifier is AS_none inside a record decl"); } |