Lines Matching refs:Result

35 translateEdits(const MatchResult &Result, ArrayRef<ASTEdit> ASTEdits) {  in translateEdits()  argument
38 Expected<CharSourceRange> Range = E.TargetRange(Result); in translateEdits()
42 tooling::getFileRangeForEdit(*Range, *Result.Context); in translateEdits()
56 auto Replacement = E.Replacement->eval(Result); in translateEdits()
62 auto Note = E.Note->eval(Result); in translateEdits()
68 auto Metadata = E.Metadata(Result); in translateEdits()
79 return [Edits = std::move(Edits)](const MatchResult &Result) { in editList() argument
80 return translateEdits(Result, Edits); in editList()
85 return [Edit = std::move(Edit)](const MatchResult &Result) { in edit() argument
86 return translateEdits(Result, {Edit}); in edit()
91 return [Anchor = std::move(Anchor)](const MatchResult &Result) in noopEdit()
93 Expected<CharSourceRange> Range = Anchor(Result); in noopEdit()
99 Result.SourceManager->getSpellingLoc(Range->getBegin()); in noopEdit()
114 const MatchResult &Result) -> llvm::Expected<SmallVector<Edit, 1>> { in flattenVector() argument
117 llvm::Expected<SmallVector<Edit, 1>> Edits = G(Result); in flattenVector()
148 std::string *Result) const override { in eval()
149 Result->append(S); in eval()
224 ast_matchers::internal::BoundNodesTreeBuilder Result(*Builder); in matches() local
226 Result.setBinding(N.first, N.second); in matches()
227 if (InnerMatcher.matches(Node, Finder, &Result)) { in matches()
228 *Builder = std::move(Result); in matches()
279 void run(const MatchFinder::MatchResult &Result) override { in run() argument
282 size_t I = transformer::detail::findSelectedCase(Result, Rule); in run()
283 auto Transformations = Rule.Cases[I].Edits(Result); in run()
301 const MatchResult &Result) { in rewriteDescendantsImpl() argument
304 Callback.registerMatchers<T>(Result.Nodes, &Finder); in rewriteDescendantsImpl()
305 Finder.match(Node, *Result.Context); in rewriteDescendantsImpl()
311 const MatchResult &Result) { in rewriteDescendants() argument
312 return rewriteDescendantsImpl(Node, std::move(Rule), Result); in rewriteDescendants()
317 const MatchResult &Result) { in rewriteDescendants() argument
318 return rewriteDescendantsImpl(Node, std::move(Rule), Result); in rewriteDescendants()
323 const MatchResult &Result) { in rewriteDescendants() argument
324 return rewriteDescendantsImpl(Node, std::move(Rule), Result); in rewriteDescendants()
330 const MatchResult &Result) { in rewriteDescendants() argument
332 return rewriteDescendantsImpl(*Node, std::move(Rule), Result); in rewriteDescendants()
334 return rewriteDescendantsImpl(*Node, std::move(Rule), Result); in rewriteDescendants()
336 return rewriteDescendantsImpl(*Node, std::move(Rule), Result); in rewriteDescendants()
347 Rule = std::move(Rule)](const MatchResult &Result) in rewriteDescendants()
350 Result.Nodes.getMap(); in rewriteDescendants()
355 return detail::rewriteDescendants(It->second, std::move(Rule), Result); in rewriteDescendants()
448 SourceLocation transformer::detail::getRuleMatchLoc(const MatchResult &Result) { in getRuleMatchLoc() argument
449 auto &NodesMap = Result.Nodes.getMap(); in getRuleMatchLoc()
454 *Result.Context); in getRuleMatchLoc()
459 return Result.SourceManager->getExpansionLoc( in getRuleMatchLoc()
465 size_t transformer::detail::findSelectedCase(const MatchResult &Result, in findSelectedCase() argument
470 auto &NodesMap = Result.Nodes.getMap(); in findSelectedCase()