Home
last modified time | relevance | path

Searched refs:commonAncestor (Results 1 – 25 of 26) sorted by relevance

12

/llvm-project-15.0.7/clang-tools-extra/clangd/unittests/
H A DSelectionTests.cpp547 EXPECT_FALSE(T.commonAncestor()) << C.Code << "\n" << T; in TEST()
557 EXPECT_EQ(nodeRange(T.commonAncestor(), AST), Test.range()) in TEST()
576 ASSERT_EQ("CXXRecordDecl", nodeKind(T.commonAncestor())) << T; in TEST()
661 EXPECT_EQ("BreakStmt", T.commonAncestor()->kind()); in TEST()
662 EXPECT_EQ("WhileStmt", T.commonAncestor()->Parent->kind()); in TEST()
678 EXPECT_EQ(nullptr, T.commonAncestor()); in TEST()
692 EXPECT_EQ("IntegerLiteral", T.commonAncestor()->kind()); in TEST()
693 EXPECT_TRUE(T.commonAncestor()->Selected); in TEST()
706 EXPECT_EQ("IntegerLiteral", T.commonAncestor()->kind()); in TEST()
718 const SelectionTree::Node *Str = T.commonAncestor(); in TEST()
[all …]
H A DFindTargetTests.cpp81 const SelectionTree::Node *N = Selection.commonAncestor(); in assertNodeAndPrintDecls()
/llvm-project-15.0.7/clang-tools-extra/clangd/refactor/tweaks/
H A DExpandAutoType.cpp91 if (auto *Node = Inputs.ASTSelection.commonAncestor()) { in prepare()
138 Inputs.ASTSelection.commonAncestor()->getDeclContext()); in apply()
H A DDumpAST.cpp37 for (auto *N = Inputs.ASTSelection.commonAncestor(); N && !Node; in prepare()
139 if (auto *Node = Inputs.ASTSelection.commonAncestor()) in prepare()
H A DAddUsing.cpp138 UsingFinder(Usings, &Inputs.ASTSelection.commonAncestor()->getDeclContext(), in findInsertionPoint()
181 &Inputs.ASTSelection.commonAncestor()->getDeclContext(); in findInsertionPoint()
244 auto *Node = Inputs.ASTSelection.commonAncestor(); in prepare()
H A DObjCLocalizeStringLiteral.cpp49 const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in REGISTER_TWEAK()
H A DRawStringLiteral.cpp75 const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in prepare()
H A DObjCMemberwiseInitializer.cpp197 const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in REGISTER_TWEAK()
267 const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in apply()
H A DSwapIfBranches.cpp51 for (const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in REGISTER_TWEAK()
H A DAnnotateHighlightings.cpp41 for (auto *N = Inputs.ASTSelection.commonAncestor(); N && !CommonDecl; in REGISTER_TWEAK()
H A DSpecialMembers.cpp104 if (auto *N = Inputs.ASTSelection.commonAncestor()) in prepare()
H A DRemoveUsingNamespace.cpp106 auto *CA = Inputs.ASTSelection.commonAncestor(); in prepare()
H A DPopulateSwitch.cpp86 const SelectionTree::Node *CA = Sel.ASTSelection.commonAncestor(); in REGISTER_TWEAK()
H A DMemberwiseConstructor.cpp49 if (auto *N = Inputs.ASTSelection.commonAncestor()) in prepare()
H A DDefineOutline.cpp383 Source = getSelectedFunction(Sel.ASTSelection.commonAncestor()); in prepare()
H A DDefineInline.cpp400 const SelectionTree::Node *SelNode = Sel.ASTSelection.commonAncestor(); in prepare()
H A DExtractVariable.cpp510 computeExtractedExpr(Inputs.ASTSelection.commonAncestor())) in REGISTER_TWEAK()
H A DExtractFunction.cpp867 const Node *CommonAnc = Inputs.ASTSelection.commonAncestor(); in prepare()
/llvm-project-15.0.7/mlir/lib/IR/
H A DSymbolTable.cpp660 Operation *commonAncestor = symbol->getParentOp(); in collectSymbolScopes() local
662 if (limitAncestors.count(commonAncestor)) in collectSymbolScopes()
664 } while ((commonAncestor = commonAncestor->getParentOp())); in collectSymbolScopes()
665 assert(commonAncestor && "'limit' and 'symbol' have no common ancestor"); in collectSymbolScopes()
671 collectValidReferencesFor(symbol, symName, commonAncestor, references)); in collectSymbolScopes()
674 if (commonAncestor == limit) { in collectSymbolScopes()
/llvm-project-15.0.7/clang-tools-extra/clangd/
H A DSelection.h146 const Node *commonAncestor() const;
H A DSemanticSelection.cpp124 for (const auto *Node = ST.commonAncestor(); Node != nullptr; in getSemanticRanges()
H A DSelection.cpp51 const auto *Common = S.commonAncestor(); in recordMetrics()
1069 const Node *SelectionTree::commonAncestor() const { in commonAncestor() function in clang::clangd::SelectionTree
H A DXRefs.cpp176 if (const SelectionTree::Node *N = ST.commonAncestor()) { in getDeclAtPositionWithRelations()
1243 if (const SelectionTree::Node *N = ST.commonAncestor()) { in findDocumentHighlights()
1787 Result = RecordFromNode(ST.commonAncestor()); in findRecordTypeAt()
1985 Result = SymbolsFromNode(ST.commonAncestor()); in findType()
H A DHover.cpp1032 if (const SelectionTree::Node *N = ST.commonAncestor()) { in getHover()
/llvm-project-15.0.7/clang-tools-extra/clangd/refactor/
H A DRename.cpp148 const SelectionTree::Node *SelectedNode = Selection.commonAncestor(); in locateDeclAt()

12