|
reference, declaration → definition
definition → references, declarations, derived classes, virtual overrides
reference to multiple definitions → definitions
unreferenced
|
References
tools/clang/include/clang/AST/ASTNodeTraverser.h 210 if (const auto *D = N.get<Decl>())
212 else if (const auto *S = N.get<Stmt>())
214 else if (const auto *QT = N.get<QualType>())
216 else if (const auto *T = N.get<Type>())
218 else if (const auto *C = N.get<CXXCtorInitializer>())
220 else if (const auto *C = N.get<OMPClause>())
222 else if (const auto *T = N.get<TemplateArgument>())
tools/clang/include/clang/ASTMatchers/ASTMatchers.h 6474 if(const auto *FuncDeclNode = CurNode.get<FunctionDecl>()) {
6478 } else if(const auto *LambdaExprNode = CurNode.get<LambdaExpr>()) {
tools/clang/include/clang/ASTMatchers/ASTMatchersInternal.h 165 return It->second.get<T>();
tools/clang/include/clang/Tooling/Refactoring/ASTSelection.h 112 return SelectedNode.get().Node.get<Stmt>();
114 return SelectedNode.get().Children[I].Node.get<Stmt>();
tools/clang/lib/AST/ASTContext.cpp10443 if (const auto *D = ParentStack.back().get<Decl>())
10445 else if (const auto *S = ParentStack.back().get<Stmt>())
tools/clang/lib/AST/ASTTypeTraits.cpp 129 if (const TemplateArgument *TA = get<TemplateArgument>())
131 else if (const TemplateName *TN = get<TemplateName>())
133 else if (const NestedNameSpecifier *NNS = get<NestedNameSpecifier>())
135 else if (const NestedNameSpecifierLoc *NNSL = get<NestedNameSpecifierLoc>()) {
140 } else if (const QualType *QT = get<QualType>())
142 else if (const TypeLoc *TL = get<TypeLoc>())
144 else if (const Decl *D = get<Decl>())
146 else if (const Stmt *S = get<Stmt>())
148 else if (const Type *T = get<Type>())
155 if (const Decl *D = get<Decl>())
157 else if (const Stmt *S = get<Stmt>())
159 else if (const Type *T = get<Type>())
166 if (const CXXCtorInitializer *CCI = get<CXXCtorInitializer>())
168 if (const NestedNameSpecifierLoc *NNSL = get<NestedNameSpecifierLoc>())
170 if (const TypeLoc *TL = get<TypeLoc>())
172 if (const Decl *D = get<Decl>())
174 if (const Stmt *S = get<Stmt>())
176 if (const auto *C = get<OMPClause>())
tools/clang/lib/ASTMatchers/ASTMatchFinder.cpp 106 if (const Decl *D = DynNode.get<Decl>())
108 else if (const Stmt *S = DynNode.get<Stmt>())
111 DynNode.get<NestedNameSpecifier>())
114 DynNode.get<NestedNameSpecifierLoc>())
116 else if (const QualType *Q = DynNode.get<QualType>())
118 else if (const TypeLoc *T = DynNode.get<TypeLoc>())
120 else if (const auto *C = DynNode.get<CXXCtorInitializer>())
486 if (auto *N = Node.get<Decl>()) {
488 } else if (auto *N = Node.get<Stmt>()) {
490 } else if (auto *N = Node.get<Type>()) {
492 } else if (auto *N = Node.get<QualType>()) {
494 } else if (auto *N = Node.get<NestedNameSpecifier>()) {
496 } else if (auto *N = Node.get<NestedNameSpecifierLoc>()) {
498 } else if (auto *N = Node.get<TypeLoc>()) {
500 } else if (auto *N = Node.get<CXXCtorInitializer>()) {
687 if (!Node.get<TranslationUnitDecl>() &&
tools/clang/lib/Tooling/ASTDiff/ASTDiff.cpp 390 if (const auto *D = P.get<Decl>())
392 S = P.get<Stmt>();
414 if (auto *S = DTN.get<Stmt>())
416 if (auto *D = DTN.get<Decl>())
418 if (auto *Init = DTN.get<CXXCtorInitializer>())
693 if (auto *ND = ASTNode.get<NamedDecl>()) {
701 if (auto *ND = ASTNode.get<NamedDecl>()) {
1001 if (auto *ThisExpr = N.ASTNode.get<CXXThisExpr>()) {
tools/clang/lib/Tooling/Refactoring/ASTSelection.cpp 219 if (const Decl *D = Node.Node.get<Decl>()) {
223 } else if (const Stmt *S = Node.Node.get<Stmt>()) {
291 const Stmt *S = Node.get().Node.get<Stmt>();
293 const Stmt *Parent = Parents[Parents.size() - 1].get().Node.get<Stmt>();
302 Parents[Parents.size() - ParentIndex - 1].get().Node.get<Stmt>();
346 if (ASTSelection.Node.get<DeclStmt>()) {
393 if (!Selected.Node.get().Node.get<Stmt>())
395 const Stmt *CodeRangeStmt = Selected.Node.get().Node.get<Stmt>();
426 if (const auto *D = Node.get<Decl>()) {
436 IsPrevCompound = Node.get<CompoundStmt>() != nullptr;
444 if (const auto *D = Node.get<Decl>()) {
tools/clang/lib/Tooling/Refactoring/Rename/USRLocFinder.cpp 360 if (const auto *NSL = Parents[0].get<NestedNameSpecifierLoc>()) {
365 if (const auto *TL = Parents[0].get<TypeLoc>())
471 return Parents[0].template get<Decl>();
482 return Parents[0].get<TypeLoc>();
tools/clang/lib/Tooling/Transformer/RangeSelector.cpp 134 return Node->get<Stmt>() != nullptr && Node->get<Expr>() == nullptr
134 return Node->get<Stmt>() != nullptr && Node->get<Expr>() == nullptr
179 if (auto *M = Node->get<clang::MemberExpr>())
192 if (const auto *D = Node.get<NamedDecl>()) {
206 if (const auto *E = Node.get<DeclRefExpr>()) {
212 if (const auto *I = Node.get<CXXCtorInitializer>()) {
241 if (const auto *Arg = N->get<T>())
tools/clang/tools/extra/clang-tidy/bugprone/MultipleStatementMacroCheck.cpp 28 const auto *Parent = Parents[0].get<Stmt>();
tools/clang/tools/extra/clang-tidy/bugprone/SuspiciousMissingCommaCheck.cpp 26 if (Parents.size() == 1 && Parents[0].get<ParenExpr>() != nullptr)
tools/clang/tools/extra/clang-tidy/cppcoreguidelines/ProBoundsArrayToPointerDecayCheck.cpp 42 E = Parents[0].get<Expr>();
tools/clang/tools/extra/clang-tidy/modernize/LoopConvertCheck.cpp 398 if (const auto *Cast = Parents[0].get<ImplicitCastExpr>()) {
584 if (const auto *Paren = Parents[0].get<ParenExpr>()) {
589 } else if (const auto *UOP = Parents[0].get<UnaryOperator>()) {
tools/clang/tools/extra/clang-tidy/modernize/MakeSmartPtrCheck.cpp 263 if (const Expr *Parent = Node.get<ParenExpr>()) {
tools/clang/tools/extra/clang-tidy/modernize/UseNullptrCheck.cpp 290 if (const auto *D = ContainingAncestor.get<Decl>())
292 else if (const auto *S = ContainingAncestor.get<Stmt>())
427 if (!Parent.get<InitListExpr>())
435 if (const auto *D = Parent.get<Decl>())
437 else if (const auto *S = Parent.get<Stmt>())
tools/clang/tools/extra/clang-tidy/readability/ImplicitBoolConversionCheck.cpp 105 Parent = Context.getParents(*Parent)[0].get<Stmt>();
226 const Stmt *S = N.get<Stmt>();
tools/clang/tools/extra/clang-tidy/readability/MagicNumbersCheck.cpp 29 const auto *AsDecl = Node.get<clang::DeclaratorDecl>();
37 if (Node.get<clang::EnumConstantDecl>() != nullptr)
118 Parent.get<SubstNonTypeTemplateParmExpr>();
tools/clang/tools/extra/clang-tidy/readability/MisleadingIndentationCheck.cpp 24 if (const auto *PrecedingIf = parents[0].get<IfStmt>()) {
tools/clang/tools/extra/clang-tidy/readability/RedundantDeclarationCheck.cpp 54 if (Parent.get<FriendDecl>())
tools/clang/tools/extra/clang-tidy/utils/ExprSequence.cpp 40 if (const auto *S = Node.get<Stmt>()) {
tools/clang/tools/extra/clangd/FindTarget.cpp 347 if (const Decl *D = N.get<Decl>())
349 else if (const Stmt *S = N.get<Stmt>())
351 else if (const NestedNameSpecifierLoc *NNSL = N.get<NestedNameSpecifierLoc>())
353 else if (const NestedNameSpecifier *NNS = N.get<NestedNameSpecifier>())
355 else if (const TypeLoc *TL = N.get<TypeLoc>())
357 else if (const QualType *QT = N.get<QualType>())
359 else if (const CXXCtorInitializer *CCI = N.get<CXXCtorInitializer>())
673 if (auto *D = N.get<Decl>())
675 if (auto *E = N.get<Expr>())
677 if (auto *NNSL = N.get<NestedNameSpecifierLoc>())
681 if (const TypeLoc *TL = N.get<TypeLoc>())
683 if (const CXXCtorInitializer *CCI = N.get<CXXCtorInitializer>()) {
tools/clang/tools/extra/clangd/Selection.cpp 126 if (const TypeLoc *TL = N.get<TypeLoc>()) {
370 if (const Decl *D = N.get<Decl>()) {
518 if (const Decl* Current = CurrentNode->ASTNode.get<Decl>()) {
tools/clang/tools/extra/clangd/SemanticSelection.cpp 45 if (const Decl *D = Node->ASTNode.get<Decl>()) {
tools/clang/tools/extra/clangd/refactor/tweaks/AnnotateHighlightings.cpp 40 CommonDecl = N->ASTNode.get<Decl>();
tools/clang/tools/extra/clangd/refactor/tweaks/DefineInline.cpp 87 if (const FunctionDecl *FD = AstNode.get<FunctionDecl>())
89 if (AstNode.get<CompoundStmt>() &&
92 return P->ASTNode.get<FunctionDecl>();
tools/clang/tools/extra/clangd/refactor/tweaks/DumpAST.cpp 53 return N.get<Decl>() || N.get<Stmt>() || N.get<Type>();
53 return N.get<Decl>() || N.get<Stmt>() || N.get<Type>();
53 return N.get<Decl>() || N.get<Stmt>() || N.get<Type>();
112 if (auto *D = Node->ASTNode.get<Decl>())
tools/clang/tools/extra/clangd/refactor/tweaks/ExpandAutoType.cpp 62 if (auto *TypeNode = Node->ASTNode.get<TypeLoc>()) {
tools/clang/tools/extra/clangd/refactor/tweaks/ExtractFunction.cpp 94 if (!N->ASTNode.get<Stmt>())
101 if (N->Selected == SelectionTree::Unselected && !N->ASTNode.get<DeclStmt>())
137 if (Parent->ASTNode.get<DeclStmt>())
175 RootStmts.insert(Child->ASTNode.get<Stmt>());
183 if (CurNode->ASTNode.get<LambdaExpr>())
185 if (const FunctionDecl *Func = CurNode->ASTNode.get<FunctionDecl>()) {
234 if (Child->ASTNode.get<Expr>())
239 if (Child->ASTNode.get<Stmt>() == EnclosingFunc->getBody())
576 ExtZone.getLastRootStmt()->ASTNode.get<Stmt>(), FuncBodyRange, SM,
tools/clang/tools/extra/clangd/refactor/tweaks/ExtractVariable.cpp 90 Expr = Node->ASTNode.get<clang::Expr>();
123 if (const clang::Stmt *Stmt = InsertionPoint->ASTNode.get<clang::Stmt>()) {
138 if (InsertionPoint->ASTNode.get<VarDecl>())
145 const clang::Stmt *CurInsertionPoint = CurNode->ASTNode.get<Stmt>();
149 if (const clang::Stmt *CurParent = CurNode->Parent->ASTNode.get<Stmt>()) {
212 llvm::dyn_cast_or_null<BinaryOperator>(N.ASTNode.get<Expr>())) {
220 N.ASTNode.get<Expr>())) {
228 const Expr *E = Child->ASTNode.get<Expr>();
257 if (SM.getFileID(Child->ASTNode.get<Expr>()->getExprLoc()) != F)
329 llvm::dyn_cast_or_null<CallExpr>(MaybeCall->ASTNode.get<Expr>());
332 if (CE->getCallee() != MaybeCallee.ASTNode.get<Expr>())
365 const Expr *E = N->ASTNode.get<Expr>();
391 childExprIsStmt(OuterImplicit.Parent->ASTNode.get<Stmt>(),
392 OuterImplicit.ASTNode.get<Expr>()))
407 const clang::Expr *SelectedExpr = N->ASTNode.get<clang::Expr>();
tools/clang/tools/extra/clangd/refactor/tweaks/RawStringLiteral.cpp 84 Str = dyn_cast_or_null<StringLiteral>(N->ASTNode.get<Stmt>());
tools/clang/tools/extra/clangd/refactor/tweaks/RemoveUsingNamespace.cpp 88 return Node->Parent && Node->Parent->ASTNode.get<TranslationUnitDecl>();
108 TargetDirective = CA->ASTNode.get<UsingDirectiveDecl>();
tools/clang/tools/extra/clangd/refactor/tweaks/SwapIfBranches.cpp 54 if (dyn_cast_or_null<CompoundStmt>(N->ASTNode.get<Stmt>()))
56 If = dyn_cast_or_null<IfStmt>(N->ASTNode.get<Stmt>());
tools/clang/tools/extra/clangd/unittests/SelectionTests.cpp 45 if (llvm::isa_and_nonnull<TranslationUnitDecl>(N->ASTNode.get<Decl>()))
332 auto *D = dyn_cast<CXXRecordDecl>(T.commonAncestor()->ASTNode.get<Decl>());
tools/clang/unittests/ASTMatchers/ASTMatchersTest.h 433 EXPECT_EQ(Nodes->getNodeAs<T>(Id), I->second.get<T>());
438 M.find(Id)->second.template get<T>() == nullptr);
tools/clang/unittests/Tooling/ASTSelectionTest.cpp 98 const auto *ND = Node.Node.get<NamedDecl>();
109 checkNodeImpl(isa<T>(StmtNode.Node.get<Stmt>()), StmtNode, SelectionKind,
120 checkNodeImpl(isa<T>(DeclNode.Node.get<Decl>()), DeclNode, SelectionKind,
729 isa<TranslationUnitDecl>(Parents[0].get().Node.get<Decl>()));
731 EXPECT_TRUE(isa<FunctionDecl>(Parents[1].get().Node.get<Decl>()));
733 EXPECT_TRUE(isa<CompoundStmt>(Parents[2].get().Node.get<Stmt>()));
750 isa<TranslationUnitDecl>(Parents[0].get().Node.get<Decl>()));
752 EXPECT_TRUE(isa<FunctionDecl>(Parents[1].get().Node.get<Decl>()));
754 EXPECT_TRUE(isa<CompoundStmt>(Parents[2].get().Node.get<Stmt>()));
804 isa<TranslationUnitDecl>(Parents[0].get().Node.get<Decl>()));
806 EXPECT_TRUE(isa<VarDecl>(Parents[1].get().Node.get<Decl>()));
832 isa<TranslationUnitDecl>(Parents[0].get().Node.get<Decl>()));
834 EXPECT_TRUE(isa<FunctionDecl>(Parents[1].get().Node.get<Decl>()));
836 EXPECT_TRUE(isa<CompoundStmt>(Parents[2].get().Node.get<Stmt>()));
838 EXPECT_TRUE(isa<CompoundStmt>(Parents[3].get().Node.get<Stmt>()));
862 isa<TranslationUnitDecl>(Parents[0].get().Node.get<Decl>()));
864 EXPECT_TRUE(isa<FunctionDecl>(Parents[1].get().Node.get<Decl>()));
866 EXPECT_TRUE(isa<CompoundStmt>(Parents[2].get().Node.get<Stmt>()));
890 isa<TranslationUnitDecl>(Parents[0].get().Node.get<Decl>()));
892 EXPECT_TRUE(isa<FunctionDecl>(Parents[1].get().Node.get<Decl>()));
894 EXPECT_TRUE(isa<CompoundStmt>(Parents[2].get().Node.get<Stmt>()));
939 isa<TranslationUnitDecl>(Parents[0].get().Node.get<Decl>()));
941 EXPECT_TRUE(isa<ObjCImplDecl>(Parents[1].get().Node.get<Decl>()));
943 EXPECT_TRUE(isa<ObjCMethodDecl>(Parents[2].get().Node.get<Decl>()));
945 EXPECT_TRUE(isa<CompoundStmt>(Parents[3].get().Node.get<Stmt>()));
963 isa<TranslationUnitDecl>(Parents[0].get().Node.get<Decl>()));
965 EXPECT_TRUE(isa<ObjCImplDecl>(Parents[1].get().Node.get<Decl>()));
967 EXPECT_TRUE(isa<ObjCMethodDecl>(Parents[2].get().Node.get<Decl>()));
969 EXPECT_TRUE(isa<CompoundStmt>(Parents[3].get().Node.get<Stmt>()));
1080 .Node.get<Stmt>()));