| /llvm-project-15.0.7/clang-tools-extra/clangd/ |
| H A D | Selection.h | 76 class SelectionTree { 88 llvm::function_ref<bool(SelectionTree)> Func); 94 static SelectionTree createRight(ASTContext &AST, 99 SelectionTree(const SelectionTree &) = delete; 100 SelectionTree &operator=(const SelectionTree &) = delete; 102 SelectionTree(SelectionTree &&) = default; 103 SelectionTree &operator=(SelectionTree &&) = default; 153 SelectionTree(ASTContext &AST, const syntax::TokenBuffer &Tokens, 162 const SelectionTree &T) {
|
| H A D | Selection.cpp | 40 using Node = SelectionTree::Node; 181 void update(SelectionTree::Selection &Result, SelectionTree::Selection New) { in update() 188 Result = SelectionTree::Partial; in update() 293 SelectionTree::Selection 425 SelectionTree::Selection 493 SelectionTree::Selection Result = in testTokenRange() 985 void SelectionTree::print(llvm::raw_ostream &OS, const SelectionTree::Node &N, in print() 1039 SelectionTree SelectionTree::createRight(ASTContext &AST, in createRight() 1050 SelectionTree::SelectionTree(ASTContext &AST, const syntax::TokenBuffer &Tokens, in SelectionTree() function in clang::clangd::SelectionTree 1092 const SelectionTree::Node &SelectionTree::Node::ignoreImplicit() const { in ignoreImplicit() [all …]
|
| H A D | SemanticSelection.cpp | 122 SelectionTree ST = SelectionTree::createRight( in getSemanticRanges()
|
| H A D | XRefs.cpp | 175 auto ResultFromTree = [&](SelectionTree ST) { in getDeclAtPositionWithRelations() 176 if (const SelectionTree::Node *N = ST.commonAncestor()) { in getDeclAtPositionWithRelations() 191 SelectionTree::createEach(AST.getASTContext(), AST.getTokens(), Offset, in getDeclAtPositionWithRelations() 1242 auto TryTree = [&](SelectionTree ST) { in findDocumentHighlights() 1243 if (const SelectionTree::Node *N = ST.commonAncestor()) { in findDocumentHighlights() 1268 SelectionTree::createEach(AST.getASTContext(), AST.getTokens(), Offset, in findDocumentHighlights() 1743 auto RecordFromNode = [&AST](const SelectionTree::Node *N) { in findRecordTypeAt() 1785 SelectionTree::createEach(AST.getASTContext(), AST.getTokens(), *Offset, in findRecordTypeAt() 1786 *Offset, [&](SelectionTree ST) { in findRecordTypeAt() 1795 static QualType typeForNode(const SelectionTree::Node *N) { in typeForNode() [all …]
|
| H A D | Hover.cpp | 452 llvm::Optional<std::string> printExprValue(const SelectionTree::Node *N, in printExprValue() 874 void maybeAddCalleeArgInfo(const SelectionTree::Node *N, HoverInfo &HI, in maybeAddCalleeArgInfo() 1030 SelectionTree ST = in getHover() 1031 SelectionTree::createRight(AST.getASTContext(), TB, Offset, Offset); in getHover() 1032 if (const SelectionTree::Node *N = ST.commonAncestor()) { in getHover()
|
| H A D | ClangdServer.cpp | 601 SelectionTree::createEach( in tweakSelection() 603 [&](SelectionTree T) { in tweakSelection() 976 bool Success = SelectionTree::createEach( in getAST() 978 [&](SelectionTree T) { in getAST() 979 if (const SelectionTree::Node *N = T.commonAncestor()) { in getAST()
|
| /llvm-project-15.0.7/clang-tools-extra/clangd/unittests/ |
| H A D | SelectionTests.cpp | 36 return SelectionTree::createRight( in makeSelectionTree() 63 std::string nodeKind(const SelectionTree::Node *N) { in nodeKind() 67 std::vector<const SelectionTree::Node *> allNodes(const SelectionTree &T) { in allNodes() 70 const SelectionTree::Node *N = Result[I]; in allNodes() 581 TEST(SelectionTree, Metrics) { in TEST() argument 637 if (N->Selected == SelectionTree::Complete) in TEST() 732 SelectionTree::createEach( in TEST() 749 [&](SelectionTree T) { in TEST() 758 [&](SelectionTree T) { in TEST() 767 [&](SelectionTree T) { in TEST() [all …]
|
| H A D | FeatureModulesTests.cpp | 50 SelectionTree::createRight(AST.getASTContext(), AST.getTokens(), 0, 0); in TEST()
|
| H A D | FindTargetTests.cpp | 79 auto Selection = SelectionTree::createRight( in assertNodeAndPrintDecls() 81 const SelectionTree::Node *N = Selection.commonAncestor(); in assertNodeAndPrintDecls()
|
| /llvm-project-15.0.7/clang-tools-extra/clangd/refactor/tweaks/ |
| H A D | ExtractVariable.cpp | 55 const SelectionTree::Node *ExprNode; 153 [](const SelectionTree::Node *InsertionPoint) -> bool { in computeInsertionPoint() 173 for (const SelectionTree::Node *CurNode = getExprNode(); in computeInsertionPoint() 239 bool parse(const SelectionTree::Node &N) { in parse() 354 const SelectionTree::Node *getCallExpr(const SelectionTree::Node *DeclRef) { in getCallExpr() 356 const SelectionTree::Node *MaybeCall = MaybeCallee.Parent; in getCallExpr() 395 bool eligibleForExtraction(const SelectionTree::Node *N) { in eligibleForExtraction() 456 const SelectionTree::Node *computeExtractedExpr(const SelectionTree::Node *N) { in computeExtractedExpr() 459 const SelectionTree::Node *TargetNode = N; in computeExtractedExpr() 466 if (const SelectionTree::Node *Call = getCallExpr(N)) in computeExtractedExpr() [all …]
|
| H A D | ExpandAutoType.cpp | 54 bool isStructuredBindingType(const SelectionTree::Node *N) { in isStructuredBindingType() 64 bool isDeducedAsLambda(const SelectionTree::Node *Node, SourceLocation Loc) { in isDeducedAsLambda() 83 bool isTemplateParam(const SelectionTree::Node *Node) { in isTemplateParam()
|
| H A D | ObjCMemberwiseInitializer.cpp | 186 paramsForSelection(const SelectionTree::Node *N); 197 const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in REGISTER_TWEAK() 236 ObjCMemberwiseInitializer::paramsForSelection(const SelectionTree::Node *N) { in paramsForSelection() 267 const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in apply()
|
| H A D | DefineInline.cpp | 70 const FunctionDecl *getSelectedFunction(const SelectionTree::Node *SelNode) { in getSelectedFunction() 75 SelNode->Selected == SelectionTree::Complete) { in getSelectedFunction() 76 if (const SelectionTree::Node *P = SelNode->Parent) in getSelectedFunction() 400 const SelectionTree::Node *SelNode = Sel.ASTSelection.commonAncestor(); in prepare()
|
| H A D | PopulateSwitch.cpp | 86 const SelectionTree::Node *CA = Sel.ASTSelection.commonAncestor(); in REGISTER_TWEAK() 98 if (const SelectionTree::Node *Parent = CA->outerImplicit().Parent) in REGISTER_TWEAK()
|
| H A D | ExtractFunction.cpp | 81 using Node = SelectionTree::Node; 106 if (N->Selected == SelectionTree::Partial) in isRootStmt() 110 if (N->Selected == SelectionTree::Unselected && !N->ASTNode.get<DeclStmt>()) in isRootStmt() 130 case SelectionTree::Selection::Unselected: in getParentOfRootStmts() 135 case SelectionTree::Selection::Partial: in getParentOfRootStmts() 138 case SelectionTree::Selection::Complete: in getParentOfRootStmts()
|
| H A D | DefineOutline.cpp | 48 const FunctionDecl *getSelectedFunction(const SelectionTree::Node *SelNode) { in getSelectedFunction() 55 SelNode->Selected == SelectionTree::Complete) { in getSelectedFunction() 56 if (const SelectionTree::Node *P = SelNode->Parent) in getSelectedFunction()
|
| H A D | ObjCLocalizeStringLiteral.cpp | 49 const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in REGISTER_TWEAK()
|
| H A D | RawStringLiteral.cpp | 75 const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in prepare()
|
| H A D | SwapIfBranches.cpp | 51 for (const SelectionTree::Node *N = Inputs.ASTSelection.commonAncestor(); in REGISTER_TWEAK()
|
| H A D | RemoveUsingNamespace.cpp | 88 bool isTopLevelDecl(const SelectionTree::Node *Node) { in isTopLevelDecl()
|
| /llvm-project-15.0.7/clang-tools-extra/clangd/refactor/ |
| H A D | Tweak.h | 51 unsigned RangeEnd, SelectionTree ASTSelection, 67 SelectionTree ASTSelection;
|
| H A D | Tweak.cpp | 63 SelectionTree ASTSelection, in Selection()
|
| H A D | Rename.cpp | 146 SelectionTree Selection = SelectionTree::createRight( in locateDeclAt() 148 const SelectionTree::Node *SelectedNode = Selection.commonAncestor(); in locateDeclAt()
|
| /llvm-project-15.0.7/clang-tools-extra/clangd/unittests/tweaks/ |
| H A D | TweakTesting.cpp | 67 SelectionTree::createEach(AST.getASTContext(), AST.getTokens(), Range.Begin, in applyTweak() 68 Range.End, [&](SelectionTree ST) { in applyTweak()
|
| /llvm-project-15.0.7/clang-tools-extra/clangd/tool/ |
| H A D | Check.cpp | 235 auto Tree = SelectionTree::createRight(AST->getASTContext(), in testLocationFeatures()
|