rsmith accepted this revision. rsmith added inline comments.
================ Comment at: Sema/SemaDecl.cpp:4659-4661 + (isa<TranslationUnitDecl>(OwnerScope) || + (isa<NamespaceDecl>(OwnerScope) && + cast<NamespaceDecl>(OwnerScope)->getDeclName()))) { ---------------- jkorous wrote: > rsmith wrote: > > vsapsai wrote: > > > Checked if we need to do the same change s/Owner/OwnerScope/ elsewhere in > > > this method and looks like it is not required. We care if the owner is a > > > Record and we don't allow linkage specification in classes, so skipping > > > linkage scopes doesn't give us anything. > > While you're here, `OwnerScope->isFileContext() && > > !OwnerScope->isInlineNamespace()` might be clearer. Or at least replace the > > `getDeclName()` with `!isInlineNamespace()`. > I'd like to explicitly flag this - we are interested in non-anonymous > namespaces not non-inline namespaces, right? Sorry, yes, thinko on my part. https://reviews.llvm.org/D45884 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits