Lines Matching defs:Decl
11 #include "clang/AST/Decl.h"
61 const auto *Decl = Result.Nodes.getNodeAs<FriendDecl>("friend_decl");
62 assert(Decl && "Decl is neither record_decl nor friend decl!");
73 if (const TypeSourceInfo *Tsi = Decl->getFriendType()) {
88 if (ParentDecl1->getDeclKind() == Decl::TranslationUnit ||
89 ParentDecl2->getDeclKind() == Decl::TranslationUnit) {
92 assert(ParentDecl1->getDeclKind() == Decl::Namespace &&
94 assert(ParentDecl2->getDeclKind() == Decl::Namespace &&
101 static std::string getNameOfNamespace(const CXXRecordDecl *Decl) {
102 const auto *ParentDecl = Decl->getLexicalParent();
103 if (ParentDecl->getDeclKind() == Decl::TranslationUnit) {
131 for (const auto *Decl : Declarations) {
132 if (Decl == CurDecl) {
136 !haveSameNamespaceOrTranslationUnit(CurDecl, Decl)) {
140 << CurDecl << getNameOfNamespace(Decl);
141 diag(Decl->getLocation(), "a declaration of %0 is found here",
143 << Decl;