summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/AST')
-rw-r--r--clang/lib/AST/DeclBase.cpp5
-rw-r--r--clang/lib/AST/DeclPrinter.cpp4
2 files changed, 1 insertions, 8 deletions
diff --git a/clang/lib/AST/DeclBase.cpp b/clang/lib/AST/DeclBase.cpp
index c24dac91042..acdbdbe4223 100644
--- a/clang/lib/AST/DeclBase.cpp
+++ b/clang/lib/AST/DeclBase.cpp
@@ -385,11 +385,6 @@ void Decl::CheckAccessDeclContext() const {
!isa<CXXRecordDecl>(getDeclContext()))
return;
- // FIXME: This check should not be necessary - If a friend decl refers to an
- // undeclared decl, then that decl shouldn't be in any decl context.
- if (getFriendObjectKind() == FOK_Undeclared)
- return;
-
assert(Access != AS_none &&
"Access specifier is AS_none inside a record decl");
}
diff --git a/clang/lib/AST/DeclPrinter.cpp b/clang/lib/AST/DeclPrinter.cpp
index 275f2db82b5..275fa697237 100644
--- a/clang/lib/AST/DeclPrinter.cpp
+++ b/clang/lib/AST/DeclPrinter.cpp
@@ -203,9 +203,7 @@ void DeclPrinter::VisitDeclContext(DeclContext *DC, bool Indent) {
if (PrintAccess) {
AccessSpecifier AS = D->getAccess();
- if (AS != CurAS &&
- // FIXME: This check shouldn't be necessary.
- D->getFriendObjectKind() == Decl::FOK_Undeclared) {
+ if (AS != CurAS) {
Print(AS);
Out << ":\n";
CurAS = AS;
OpenPOWER on IntegriCloud