reference, declarationdefinition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced

References

tools/clang/include/clang/ASTMatchers/ASTMatchers.h
 3251   return callExpr(hasDeclaration(InnerMatcher)).matches(Node, Finder, Builder);
 3302     return qualType(hasDeclaration(InnerMatcher)).matches(QT, Finder, Builder);
 3355   return pointsTo(qualType(hasDeclaration(InnerMatcher)))
 3416   return references(qualType(hasDeclaration(InnerMatcher)))
 4025       if (expr(anyOf(cxxConstructExpr(hasDeclaration(cxxConstructorDecl(
tools/clang/lib/ASTMatchers/Dynamic/Registry.cpp
  262   REGISTER_MATCHER(hasDeclaration);
tools/clang/lib/Analysis/ExprMutationAnalyzer.cpp
  262   const auto NotInstantiated = unless(hasDeclaration(isInstantiated()));
  388   const auto IsInstantiated = hasDeclaration(isInstantiated());
  389   const auto FuncDecl = hasDeclaration(functionDecl().bind("func"));
tools/clang/lib/StaticAnalyzer/Checkers/NumberObjectConversionChecker.cpp
  202               typedefType(hasDeclaration(anyOf(
  212                   recordType(hasDeclaration(
  225                       qualType(hasDeclaration(
  243       qualType(typedefType(hasDeclaration(
  256                unless(typedefType(hasDeclaration(
tools/clang/lib/StaticAnalyzer/Checkers/OSObjectCStyleCast.cpp
   60   return hasType(pointerType(pointee(hasDeclaration(DeclM))));
tools/clang/lib/StaticAnalyzer/Checkers/UninitializedObject/UninitializedObjectChecker.cpp
  541   auto FieldAccessM = memberExpr(hasDeclaration(equalsNode(FD))).bind("access");
tools/clang/lib/StaticAnalyzer/Core/BugReporterVisitors.cpp
  445           objcIvarRefExpr(hasDeclaration(equalsNode(Ivar))).bind(IvarBind))));
tools/clang/lib/StaticAnalyzer/Core/LoopUnrolling.cpp
  124       hasUnaryOperand(declRefExpr(hasDeclaration(VarNodeMatcher))));
tools/clang/tools/extra/clang-change-namespace/ChangeNamespace.cpp
  450               loc(qualType(hasDeclaration(DeclMatcher.bind("from_decl")))),
  452                                hasDeclaration(DeclMatcher),
  478               specifiesType(hasDeclaration(DeclMatcher.bind("from_decl"))))),
  482                        hasAncestor(typeLoc(loc(qualType(hasDeclaration(
tools/clang/tools/extra/clang-include-fixer/find-all-symbols/FindAllSymbols.cpp
  218               loc(qualType(hasDeclaration(Types.bind("use"))))),
  224               loc(typedefType(hasDeclaration(Typedefs.bind("use"))))),
  231               loc(templateSpecializationType(hasDeclaration(
tools/clang/tools/extra/clang-move/Move.cpp
  605       typeLoc(loc(recordType(hasDeclaration(HelperClasses.bind("used_class")))),
tools/clang/tools/extra/clang-tidy/abseil/RedundantStrcatCallsCheck.cpp
   65   const auto IsAlphanum = hasDeclaration(cxxMethodDecl(hasName("AlphaNum")));
tools/clang/tools/extra/clang-tidy/abseil/StringFindStartswithCheck.cpp
   39       recordType(hasDeclaration(StringClassMatcher)));
tools/clang/tools/extra/clang-tidy/boost/UseToStringCheck.cpp
   30           hasDeclaration(functionDecl(
   31               returns(hasDeclaration(classTemplateSpecializationDecl(
tools/clang/tools/extra/clang-tidy/bugprone/ArgumentCommentCheck.cpp
   56                unless(hasDeclaration(functionDecl(
tools/clang/tools/extra/clang-tidy/bugprone/CopyConstructorInitCheck.cpp
   30               withInitializer(cxxConstructExpr(hasDeclaration(
tools/clang/tools/extra/clang-tidy/bugprone/DanglingHandleCheck.cpp
   28       anyOf(cxxConstructExpr(hasDeclaration(cxxMethodDecl(ofClass(IsAHandle))),
   78                   recordType(hasDeclaration(recordDecl(isASequence())))))))),
   82                                 recordType(hasDeclaration(recordDecl(
  112                   recordType(hasDeclaration(cxxRecordDecl(IsAHandle))))),
  122               recordType(hasDeclaration(cxxRecordDecl(IsAHandle))))),
  157                                        recordType(hasDeclaration(recordDecl(
tools/clang/tools/extra/clang-tidy/bugprone/FoldInitTypeCheck.cpp
   30         recordType(hasDeclaration(has(typedefNameDecl(
tools/clang/tools/extra/clang-tidy/bugprone/ForwardingReferenceOverloadCheck.cpp
   70                            references(templateTypeParmType(hasDeclaration(
tools/clang/tools/extra/clang-tidy/bugprone/InaccurateEraseCheck.cpp
   38       tagType(hasDeclaration(decl(isInStdNamespace())))));
tools/clang/tools/extra/clang-tidy/bugprone/MisplacedOperatorInStrlenInAllocCheck.cpp
   54                   declRefExpr(hasDeclaration(Alloc0Func)))));
   58                   declRefExpr(hasDeclaration(Alloc1Func)))));
tools/clang/tools/extra/clang-tidy/bugprone/MoveForwardingReferenceCheck.cpp
   78                            references(templateTypeParmType(hasDeclaration(
tools/clang/tools/extra/clang-tidy/bugprone/NotNullTerminatedResultCheck.cpp
  556       hasType(hasUnqualifiedDesugaredType(recordType(hasDeclaration(recordDecl(
  560       hasDeclaration(cxxRecordDecl(hasName("::std::basic_string"))))));
tools/clang/tools/extra/clang-tidy/bugprone/SizeofContainerCheck.cpp
   23                     expr(hasType(hasCanonicalType(hasDeclaration(cxxRecordDecl(
tools/clang/tools/extra/clang-tidy/bugprone/SizeofExpressionCheck.cpp
  130                                   hasDeclaration(ConstStrLiteralDecl))))))))
tools/clang/tools/extra/clang-tidy/bugprone/StringConstructorCheck.cpp
   60       BoundStringLiteral, declRefExpr(hasDeclaration(anyOf(
   67           hasDeclaration(cxxMethodDecl(hasName("basic_string"))),
   86           hasDeclaration(cxxMethodDecl(hasName("basic_string"))),
  106       cxxConstructExpr(hasDeclaration(cxxMethodDecl(hasName("basic_string"))),
tools/clang/tools/extra/clang-tidy/bugprone/StringLiteralWithEmbeddedNulCheck.cpp
   43                        hasDeclaration(cxxMethodDecl(hasName("basic_string")))),
   47                        hasDeclaration(cxxMethodDecl(hasName("basic_string"))),
tools/clang/tools/extra/clang-tidy/bugprone/SuspiciousStringCompareCheck.cpp
  104       callExpr(hasDeclaration(FunctionCompareDecl)).bind("call");
tools/clang/tools/extra/clang-tidy/bugprone/UndelegatedConstructorCheck.cpp
   67               cxxConstructExpr(hasDeclaration(cxxConstructorDecl(ofClass(
tools/clang/tools/extra/clang-tidy/bugprone/UnhandledSelfAssignmentCheck.cpp
   55       hasDescendant(cxxConstructExpr(hasDeclaration(cxxConstructorDecl(
   80         recordType(hasDeclaration(classTemplateSpecializationDecl(
tools/clang/tools/extra/clang-tidy/bugprone/UseAfterMoveCheck.cpp
  252     auto DeclRefMatcher = declRefExpr(hasDeclaration(equalsNode(MovedVariable)),
  272       declRefExpr(hasDeclaration(equalsNode(MovedVariable))).bind("declref");
  275       recordType(hasDeclaration(cxxRecordDecl(hasAnyName(
  283       recordType(hasDeclaration(cxxRecordDecl(hasAnyName(
tools/clang/tools/extra/clang-tidy/cert/ProperlySeededRandomGeneratorCheck.cpp
   39       recordType(hasDeclaration(RandomGeneratorEngineDecl))));
tools/clang/tools/extra/clang-tidy/cert/StaticObjectExceptionCheck.cpp
   30               anyOf(hasDescendant(cxxConstructExpr(hasDeclaration(
   32                     hasDescendant(cxxNewExpr(hasDeclaration(
   34                     hasDescendant(callExpr(hasDeclaration(
tools/clang/tools/extra/clang-tidy/cert/ThrownExceptionTypeCheck.cpp
   26           cxxConstructExpr(hasDeclaration(cxxConstructorDecl(
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/InterfacesGlobalInitCheck.cpp
   27   const auto ReferencesUndefinedGlobalVar = declRefExpr(hasDeclaration(
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/OwningMemoryCheck.cpp
   68                 functionDecl(returns(qualType(hasDeclaration(OwnerDecl)))))),
  162                    unless(returns(qualType(hasDeclaration(OwnerDecl)))))
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/ProTypeMemberInitCheck.cpp
  287                        hasDeclaration(cxxConstructorDecl(
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/SlicingCheck.cpp
   58       hasDeclaration(cxxConstructorDecl(
tools/clang/tools/extra/clang-tidy/fuchsia/StaticallyConstructedObjectsCheck.cpp
   42                              hasDeclaration(cxxConstructorDecl(isConstexpr())),
tools/clang/tools/extra/clang-tidy/google/UpgradeGoogletestCaseCheck.cpp
  195       typeLoc(loc(qualType(typedefType(hasDeclaration(TestCaseTypeAlias)))),
tools/clang/tools/extra/clang-tidy/hicpp/ExceptionBaseclassCheck.cpp
   28               hasType(qualType(hasCanonicalType(hasDeclaration(cxxRecordDecl(
tools/clang/tools/extra/clang-tidy/hicpp/MultiwayPathsCoveredCheck.cpp
   32               anyOf(ignoringImpCasts(memberExpr(hasDeclaration(
tools/clang/tools/extra/clang-tidy/llvm/PreferRegisterOverUnsignedCheck.cpp
   28                                               has(memberExpr(hasDeclaration(
tools/clang/tools/extra/clang-tidy/llvm/TwineLocalCheck.cpp
   22       qualType(hasDeclaration(recordDecl(hasName("::llvm::Twine"))));
tools/clang/tools/extra/clang-tidy/misc/MisplacedConstCheck.cpp
   22                 hasType(typedefType(hasDeclaration(
tools/clang/tools/extra/clang-tidy/misc/StaticAssertCheck.cpp
   53       callExpr(hasDeclaration(functionDecl(unless(isConstexpr()))));
   64                 hasDeclaration(functionDecl(hasName("__builtin_expect"))),
tools/clang/tools/extra/clang-tidy/misc/UnconventionalAssignOperatorCheck.cpp
   28               anyOf(autoType(), hasDeclaration(equalsBoundNode("class")))))));
   31       anyOf(hasDeclaration(equalsBoundNode("class")),
   32             referenceType(pointee(hasDeclaration(equalsBoundNode("class"))))));
tools/clang/tools/extra/clang-tidy/misc/UnusedUsingDeclsCheck.cpp
   55   auto DeclMatcher = hasDeclaration(namedDecl().bind("used"));
   63       callExpr(hasDeclaration(functionDecl(
tools/clang/tools/extra/clang-tidy/modernize/DeprecatedIosBaseAliasesCheck.cpp
   39       qualType(hasDeclaration(IoStateDecl), unless(elaboratedType()));
tools/clang/tools/extra/clang-tidy/modernize/LoopConvertCheck.cpp
  168           recordType(hasDeclaration(cxxRecordDecl(hasMethod(cxxMethodDecl(
  251           hasUnqualifiedDesugaredType(recordType(hasDeclaration(cxxRecordDecl(
  257                hasUnqualifiedDesugaredType(recordType(hasDeclaration(
tools/clang/tools/extra/clang-tidy/modernize/MakeSharedCheck.cpp
   23       recordType(hasDeclaration(classTemplateSpecializationDecl(
tools/clang/tools/extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp
   85       cxxConstructExpr(hasDeclaration(decl(unless(isPublic())))))));
tools/clang/tools/extra/clang-tidy/modernize/MakeUniqueCheck.cpp
   25       recordType(hasDeclaration(classTemplateSpecializationDecl(
   31                      qualType(hasDeclaration(classTemplateSpecializationDecl(
tools/clang/tools/extra/clang-tidy/modernize/PassByValueCheck.cpp
  158                       hasDeclaration(cxxConstructorDecl(
tools/clang/tools/extra/clang-tidy/modernize/ReplaceAutoPtrCheck.cpp
   92   auto AutoPtrType = qualType(hasDeclaration(AutoPtrDecl));
tools/clang/tools/extra/clang-tidy/modernize/ReplaceRandomShuffleCheck.cpp
   39                hasDeclaration(functionDecl(hasName("::std::random_shuffle"))),
tools/clang/tools/extra/clang-tidy/modernize/ReturnBracedInitListCheck.cpp
   29           unless(anyOf(hasDeclaration(cxxConstructorDecl(isExplicit())),
tools/clang/tools/extra/clang-tidy/modernize/ShrinkToFitCheck.cpp
   30       declRefExpr(hasDeclaration(valueDecl().bind("ContainerDecl")));
   37                  declRefExpr(hasDeclaration(equalsBoundNode("ContainerDecl"))),
   41                      hasDeclaration(equalsBoundNode("ContainerDecl"))))))));
   45           on(hasType(hasCanonicalType(hasDeclaration(namedDecl(
tools/clang/tools/extra/clang-tidy/modernize/UseAutoCheck.cpp
  221   return typedefType(hasDeclaration(standardIterator()));
  227   return recordType(hasDeclaration(standardIterator()));
  233   auto HasIteratorDecl = hasDeclaration(namedDecl(hasStdIteratorName()));
  238       hasQualifier(specifiesType(templateSpecializationType(hasDeclaration(
tools/clang/tools/extra/clang-tidy/modernize/UseEmplaceCheck.cpp
   55       hasDeclaration(functionDecl(hasName("push_back"))),
   63   auto IsCtorOfSmartPtr = hasDeclaration(cxxConstructorDecl(ofClass(hasAnyName(
   68       ignoringImplicit(memberExpr(hasDeclaration(fieldDecl(isBitField())))));
   81   auto IsPrivateCtor = hasDeclaration(cxxConstructorDecl(isPrivate()));
  108       hasDeclaration(cxxConstructorDecl(ofClass(hasAnyName(
tools/clang/tools/extra/clang-tidy/modernize/UseEqualsDefaultCheck.cpp
   81                     hasDeclaration(cxxConstructorDecl(isCopyConstructor())),
  101                         hasDeclaration(cxxConstructorDecl(isCopyConstructor())),
tools/clang/tools/extra/clang-tidy/modernize/UseTransparentFunctorsCheck.cpp
   48               hasDeclaration(classTemplateSpecializationDecl(
   52                       templateArgument(refersToType(qualType(hasDeclaration(
   63   Finder->addMatcher(cxxConstructExpr(hasDeclaration(cxxMethodDecl(
tools/clang/tools/extra/clang-tidy/modernize/UseUncaughtExceptionsCheck.cpp
   38   Finder->addMatcher(callExpr(hasDeclaration(functionDecl(hasName(MatchText))),
   45                               hasDeclaration(functionDecl(hasName(MatchText))))
tools/clang/tools/extra/clang-tidy/performance/FasterStringFindCheck.cpp
   77               hasType(hasUnqualifiedDesugaredType(recordType(hasDeclaration(
tools/clang/tools/extra/clang-tidy/performance/ForRangeCopyCheck.cpp
   42                        hasDeclaration(namedDecl(
tools/clang/tools/extra/clang-tidy/performance/InefficientAlgorithmCheck.cpp
   50                             hasDeclaration(decl().bind("IneffContObj")),
   59                          hasDeclaration(equalsBoundNode("IneffContObj"))))))))),
tools/clang/tools/extra/clang-tidy/performance/InefficientStringConcatenationCheck.cpp
   36           hasDeclaration(cxxRecordDecl(hasName("::std::basic_string")))))));
   52                                  hasDeclaration(decl().bind("lhsStrT")))
   55                          hasDeclaration(decl(equalsBoundNode("lhsStrT"))))))),
tools/clang/tools/extra/clang-tidy/performance/InefficientVectorOperationCheck.cpp
   93       hasDeclaration(cxxConstructorDecl(isDefaultConstructor())));
tools/clang/tools/extra/clang-tidy/performance/MoveConstructorInitCheck.cpp
   40                   withInitializer(cxxConstructExpr(hasDeclaration(
tools/clang/tools/extra/clang-tidy/performance/UnnecessaryCopyInitialization.cpp
   63                                        unless(hasDeclaration(namedDecl(
   69                                            hasDeclaration(cxxConstructorDecl(
tools/clang/tools/extra/clang-tidy/performance/UnnecessaryValueParamCheck.cpp
   84                        hasDeclaration(namedDecl(
tools/clang/tools/extra/clang-tidy/readability/ContainerSizeEmptyCheck.cpp
   35       recordType(hasDeclaration(cxxRecordDecl(isSameOrDerivedFrom(
   72           hasDeclaration(cxxConstructorDecl(isDefaultConstructor())));
   79           hasDeclaration(cxxConstructorDecl(isCopyConstructor())),
   82           hasDeclaration(cxxConstructorDecl(isMoveConstructor())),
tools/clang/tools/extra/clang-tidy/readability/DeleteNullPointerCheck.cpp
   28       cxxDeleteExpr(has(castExpr(has(memberExpr(hasDeclaration(
   34       memberExpr(hasDeclaration(fieldDecl().bind("deletedMemberPointer")))));
tools/clang/tools/extra/clang-tidy/readability/ImplicitBoolConversionCheck.cpp
  268                  has(ignoringImplicit(memberExpr(hasDeclaration(fieldDecl(hasBitWidth(1)))))),
  309       hasLHS(memberExpr(hasDeclaration(fieldDecl(hasBitWidth(1))))));
tools/clang/tools/extra/clang-tidy/readability/RedundantMemberInitCheck.cpp
   29           hasDeclaration(cxxConstructorDecl(hasParent(
tools/clang/tools/extra/clang-tidy/readability/RedundantStringCStrCheck.cpp
   75       hasDeclaration(cxxRecordDecl(hasName("::std::basic_string"))))));
   82                        hasDeclaration(cxxMethodDecl(hasName("basic_string")))),
   85           hasDeclaration(cxxMethodDecl(hasName("basic_string"))),
  162           hasDeclaration(cxxMethodDecl(hasAnyName(
tools/clang/tools/extra/clang-tidy/readability/RedundantStringInitCheck.cpp
   27                        hasDeclaration(cxxMethodDecl(hasName("basic_string")))),
   31                        hasDeclaration(cxxMethodDecl(hasName("basic_string"))),
   50                       hasDeclaration(cxxRecordDecl(hasName("basic_string")))))),
tools/clang/tools/extra/clang-tidy/readability/SimplifyBooleanExprCheck.cpp
  462   auto VarAssign = declRefExpr(hasDeclaration(decl().bind(IfAssignVarId)));
  463   auto VarRef = declRefExpr(hasDeclaration(equalsBoundNode(IfAssignVarId)));
  464   auto MemAssign = memberExpr(hasDeclaration(decl().bind(IfAssignVarId)));
  465   auto MemRef = memberExpr(hasDeclaration(equalsBoundNode(IfAssignVarId)));
tools/clang/tools/extra/clang-tidy/readability/SimplifySubscriptExprCheck.cpp
   34       recordType(hasDeclaration(cxxRecordDecl(hasAnyName(
tools/clang/tools/extra/clang-tidy/readability/StaticAccessedThroughInstanceCheck.cpp
   41       memberExpr(hasDeclaration(anyOf(cxxMethodDecl(isStaticStorageClass()),
tools/clang/tools/extra/clang-tidy/readability/UniqueptrDeleteReleaseCheck.cpp
   26       hasTemplateArgument(1, refersToType(qualType(hasDeclaration(cxxRecordDecl(
tools/clang/tools/extra/clang-tidy/utils/DeclRefExprUtils.cpp
  147           cxxConstructExpr(UsedAsConstRefArg, hasDeclaration(cxxConstructorDecl(
tools/clang/tools/extra/clang-tidy/zircon/TemporaryObjectsCheck.cpp
   32       cxxTemporaryObjectExpr(hasDeclaration(cxxConstructorDecl(hasParent(
   40                        hasDeclaration(cxxConstructorDecl(
tools/clang/unittests/AST/ASTImporterTest.cpp
  572                   declRefExpr(hasDeclaration(varDecl(hasName("ptr"))),
  584               labelStmt(hasDeclaration(labelDecl(hasName("loop"))))),
  586               addrLabelExpr(hasDeclaration(labelDecl(hasName("loop")))))));
  603           hasDeclaration(classTemplateSpecializationDecl(hasSpecializedTemplate(
tools/clang/unittests/ASTMatchers/ASTMatchersNarrowingTest.cpp
  696   TypeMatcher TypeAHasClassB = hasDeclaration(
  857     sizeOfExpr(hasArgumentOfType(hasDeclaration(recordDecl(hasName("A")))))));
  859     hasArgumentOfType(hasDeclaration(recordDecl(hasName("string")))))));
 1553         TypeMatcher(hasDeclaration(anything())),
 1566         hasDeclaration(namedDecl(hasName("x"))))));
 1568         hasDeclaration(namedDecl(hasName("y"))))));
 1630     memberExpr(hasDeclaration(fieldDecl(hasType(isInteger()))))));
 1633     memberExpr(hasDeclaration(fieldDecl(hasType(isInteger()))))));
tools/clang/unittests/ASTMatchers/ASTMatchersNodeTest.cpp
  239     callExpr(hasDeclaration(cxxMethodDecl(hasName("x"))));
  335                         hasDeclaration(
 1102                                        hasDeclaration(cxxConstructorDecl(
 1106                                        hasDeclaration(cxxConstructorDecl(
 1447                       recordType(hasDeclaration(recordDecl(hasName("S"))))));
 1449                          recordType(hasDeclaration(recordDecl(hasName("S"))))));
 1506     specifiesType(hasDeclaration(recordDecl(hasName("A")))));
tools/clang/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp
  147   TypeMatcher TypeA = hasDeclaration(recordDecl(hasName("A")));
  153     hasDeclaration(cxxRecordDecl(isDerivedFrom("A")));
  159   TypeMatcher TypeAHasClassB = hasDeclaration(
  220                         qualType(hasDeclaration(enumDecl(hasName("X")))))))));
  236       parmVarDecl(hasType(qualType(hasDeclaration(cxxRecordDecl()))))));
  240       parmVarDecl(hasType(elaboratedType(hasDeclaration(cxxRecordDecl()))))));
  246                               hasType(typedefType(hasDeclaration(decl()))))));
  254                         hasDeclaration(namedDecl(hasName("A"))))))));
  258                         hasDeclaration(namedDecl(hasName("A"))))))));
  261                           hasDeclaration(cxxRecordDecl()))))));
  267               cxxNewExpr(hasDeclaration(functionDecl(parameterCountIs(1))))));
  273                           hasDeclaration(typeAliasTemplateDecl()))))));
  301   TypeMatcher ClassX = hasDeclaration(recordDecl(hasName("X")));
  313   TypeMatcher ClassX = hasDeclaration(recordDecl(hasName("X")));
  780                       functionDecl(returns(hasDeclaration(
 1301   StatementMatcher Constructor = cxxConstructExpr(hasDeclaration(cxxMethodDecl(
 2352       hasDeclaration(namedDecl(hasName("D")))))))));
tools/clang/unittests/ASTMatchers/Dynamic/RegistryTest.cpp
  217                      specifiesType(hasDeclaration(recordDecl(hasName("A")))))))
tools/clang/unittests/Tooling/RangeSelectorTest.cpp
  100                   hasDeclaration(
tools/clang/unittests/Tooling/StencilTest.cpp
   92                      hasDeclaration(decl(hasDescendant(cxxCtorInitializer(
tools/clang/unittests/Tooling/TransformerTest.cpp
   48   return anyOf(hasDeclaration(TypeMatcher), pointsTo(TypeMatcher));