From 5c27f2bfd2e19429dd9206f9b019e11d4a570acf Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Tue, 7 Apr 2009 20:58:25 +0000 Subject: [PATCH] Allow us to ask for the access specifier of a translation unit git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68548 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/AST/DeclBase.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/AST/DeclBase.cpp b/lib/AST/DeclBase.cpp index 615bf00087..f098496f23 100644 --- a/lib/AST/DeclBase.cpp +++ b/lib/AST/DeclBase.cpp @@ -338,7 +338,8 @@ DeclContext *Decl::castToDeclContext(const Decl *D) { #ifndef NDEBUG void Decl::CheckAccessDeclContext() const { - assert((Access != AS_none || !isa(getDeclContext())) && + assert((Access != AS_none || isa(this) || + !isa(getDeclContext())) && "Access specifier is AS_none inside a record decl"); } -- 2.50.1