Home
last modified time | relevance | path

Searched refs:Replacement (Results 1 – 25 of 105) sorted by relevance

12345

/freebsd/contrib/llvm-project/clang/include/clang/Tooling/Core/
H A DReplacement.h83 class Replacement {
86 Replacement();
164 ReplacementError(replacement_error Err, Replacement New, Replacement Existing) in ReplacementError()
194 std::optional<Replacement> NewReplacement;
201 bool operator<(const Replacement &LHS, const Replacement &RHS);
204 bool operator==(const Replacement &LHS, const Replacement &RHS);
205 inline bool operator!=(const Replacement &LHS, const Replacement &RHS) {
261 llvm::Error add(const Replacement &R);
299 Replacement getReplacementInChangedCode(const Replacement &R) const;
339 std::vector<Replacement> Replacements;
[all …]
/freebsd/contrib/llvm-project/clang/lib/Tooling/Core/
H A DReplacement.cpp45 Replacement::Replacement() : FilePath(InvalidLocation) {} in Replacement() function in Replacement
47 Replacement::Replacement(StringRef FilePath, unsigned Offset, unsigned Length, in Replacement() function in Replacement
52 Replacement::Replacement(const SourceManager &Sources, SourceLocation Start, in Replacement() function in Replacement
57 Replacement::Replacement(const SourceManager &Sources, in Replacement() function in Replacement
98 bool operator<(const Replacement &LHS, const Replacement &RHS) { in operator <()
110 bool operator==(const Replacement &LHS, const Replacement &RHS) { in operator ==()
157 Replacement
207 Replacement NewR( in getCanonicalReplacements()
281 Replacement NewR( in add()
306 auto Overlap = [](const Replacement &R1, const Replacement &R2) -> bool { in add()
[all …]
/freebsd/contrib/llvm-project/clang/include/clang/Tooling/
H A DReplacementsYaml.h22 LLVM_YAML_IS_SEQUENCE_VECTOR(clang::tooling::Replacement) in LLVM_YAML_IS_SEQUENCE_VECTOR() argument
29 template <> struct MappingTraits<clang::tooling::Replacement> { in LLVM_YAML_IS_SEQUENCE_VECTOR()
35 NormalizedReplacement(const IO &, const clang::tooling::Replacement &R) in LLVM_YAML_IS_SEQUENCE_VECTOR()
39 clang::tooling::Replacement denormalize(const IO &) { in LLVM_YAML_IS_SEQUENCE_VECTOR()
40 return clang::tooling::Replacement(FilePath, Offset, Length, in LLVM_YAML_IS_SEQUENCE_VECTOR()
50 static void mapping(IO &Io, clang::tooling::Replacement &R) { in LLVM_YAML_IS_SEQUENCE_VECTOR()
51 MappingNormalization<NormalizedReplacement, clang::tooling::Replacement> in LLVM_YAML_IS_SEQUENCE_VECTOR()
/freebsd/contrib/llvm-project/clang/lib/Tooling/
H A DRefactoringCallbacks.cpp51 for (const auto &Replacement : Callback->getReplacements()) { in HandleTranslationUnit() local
53 Refactoring.FileToReplaces[std::string(Replacement.getFilePath())] in HandleTranslationUnit()
54 .add(Replacement); in HandleTranslationUnit()
56 llvm::errs() << "Skipping replacement " << Replacement.toString() in HandleTranslationUnit()
72 static Replacement replaceStmtWithText(SourceManager &Sources, const Stmt &From, in replaceStmtWithText()
74 return tooling::Replacement( in replaceStmtWithText()
77 static Replacement replaceStmtWithStmt(SourceManager &Sources, const Stmt &From, in replaceStmtWithStmt()
91 auto Err = Replace.add(tooling::Replacement( in run()
228 auto Replacement = in run() local
229 tooling::Replacement(*Result.SourceManager, &NodeMap.at(FromId), ToText, in run()
[all …]
/freebsd/contrib/llvm-project/clang/include/clang/Tooling/Transformer/
H A DRewriteRule.h48 std::string Replacement; member
110 TextGenerator Replacement; member
182 ASTEdit changeTo(RangeSelector Target, TextGenerator Replacement);
184 inline ASTEdit change(RangeSelector Target, TextGenerator Replacement) { in change() argument
185 return changeTo(std::move(Target), std::move(Replacement)); in change()
194 inline ASTEdit changeTo(TextGenerator Replacement) { in changeTo() argument
195 return changeTo(node(RootID), std::move(Replacement)); in changeTo()
198 inline ASTEdit change(TextGenerator Replacement) { in change() argument
199 return changeTo(std::move(Replacement)); in change()
205 return changeTo(before(std::move(S)), std::move(Replacement)); in insertBefore()
[all …]
/freebsd/sys/contrib/dev/acpica/compiler/
H A Dprmacros.c184 0, DefineInfo->Identifier, DefineInfo->Replacement); in PrDumpPredefinedNames()
208 char *Replacement, in PrAddDefine() argument
216 if (!Replacement) in PrAddDefine()
218 Replacement = ""; in PrAddDefine()
234 if (strcmp (Replacement, DefineInfo->Replacement)) in PrAddDefine()
250 ReplacementString = UtLocalCalloc (strlen (Replacement) + 1); in PrAddDefine()
251 strcpy (ReplacementString, Replacement); in PrAddDefine()
256 DefineInfo->Replacement = ReplacementString; in PrAddDefine()
H A Dprexpress.c242 DefineInfo->Replacement); in PrExpandMacros()
249 ReplaceString = DefineInfo->Replacement; in PrExpandMacros()
/freebsd/contrib/llvm-project/clang/lib/Tooling/Syntax/
H A DComputeReplacements.cpp100 std::string Replacement; in computeReplacements() local
102 if (ReplacedRange.empty() && Replacement.empty()) in computeReplacements()
104 llvm::cantFail(Replacements.add(tooling::Replacement( in computeReplacements()
106 Replacement))); in computeReplacements()
107 Replacement = ""; in computeReplacements()
113 Replacement += in computeReplacements()
/freebsd/contrib/llvm-project/llvm/lib/Target/AMDGPU/
H A DR600OpenCLImageTypeLoweringPass.cpp164 Value *Replacement = nullptr; in replaceImageUses() local
167 Replacement = ConstantInt::get(Int32Type, ResourceID); in replaceImageUses()
169 Replacement = &ImageSizeArg; in replaceImageUses()
171 Replacement = &ImageFormatArg; in replaceImageUses()
176 Inst->replaceAllUsesWith(Replacement); in replaceImageUses()
197 Value *Replacement = nullptr; in replaceSamplerUses() local
200 Replacement = ConstantInt::get(Int32Type, ResourceID); in replaceSamplerUses()
205 Inst->replaceAllUsesWith(Replacement); in replaceSamplerUses()
H A DAMDGPULowerModuleLDSPass.cpp522 auto Replacement = KernelToReplacement.find(kernels[i]); in buildLookupTable() local
524 (Replacement == KernelToReplacement.end()) in buildLookupTable()
958 auto Replacement = in lowerKernelScopeStructVariables() local
967 markUsedByKernel(&Func, Replacement.SGV); in lowerKernelScopeStructVariables()
971 KernelToReplacement[&Func] = Replacement; in lowerKernelScopeStructVariables()
975 M, KernelUsedVariables, Replacement, [&Func](Use &U) { in lowerKernelScopeStructVariables()
1193 LDSVariableReplacement Replacement = in runOnModule() local
1261 auto Replacement = KernelToReplacement.find(&Func); in runOnModule() local
1263 Replacement != KernelToReplacement.end(); in runOnModule()
1277 GlobalVariable *KernelStruct = Replacement->second.SGV; in runOnModule()
[all …]
H A DAMDGPURewriteOutArguments.cpp339 for (std::pair<ReturnInst *, ReplacementVec> &Replacement : Replacements) { in runOnFunction()
340 ReturnInst *RI = Replacement.first; in runOnFunction()
351 for (std::pair<Argument *, Value *> ReturnPoint : Replacement.second) in runOnFunction()
/freebsd/contrib/llvm-project/clang/lib/Tooling/Transformer/
H A DRewriteRule.cpp55 if (E.Replacement) { in translateEdits()
56 auto Replacement = E.Replacement->eval(Result); in translateEdits() local
57 if (!Replacement) in translateEdits()
58 return Replacement.takeError(); in translateEdits()
59 T.Replacement = std::move(*Replacement); in translateEdits()
126 ASTEdit transformer::changeTo(RangeSelector Target, TextGenerator Replacement) { in changeTo() argument
129 E.Replacement = std::move(Replacement); in changeTo()
181 E.Replacement = makeText(formatHeaderPath(Header, Format)); in addInclude()
H A DTransformer.cpp51 AC.replace(*Result.SourceManager, T.Range, T.Replacement)) { in convertToAtomicChanges()
56 AC.addHeader(T.Replacement); in convertToAtomicChanges()
/freebsd/contrib/llvm-project/clang/lib/Tooling/Refactoring/
H A DAtomicChange.cpp45 std::vector<clang::tooling::Replacement> Replaces;
118 for (const clang::tooling::Replacement &R : Replaces) { in getRangesForFormating()
160 tooling::Replacement(FilePath, UINT_MAX, 0, ReplacementText)); in createReplacementsForHeaders()
168 HeaderReplacements.add(Replacement(FilePath, UINT_MAX, 1, Header)); in createReplacementsForHeaders()
188 if (auto Err = Replaces.add(Replacement( in combineReplacementsInChanges()
261 return Replaces.add(Replacement(SM, Range, ReplacementText)); in replace()
266 return Replaces.add(Replacement(SM, Loc, Length, Text)); in replace()
273 Replacement R(SM, Loc, 0, Text); in insert()
284 Replacement NewR(R.getFilePath(), NewOffset, 0, Text); in insert()
/freebsd/contrib/llvm-project/llvm/lib/Transforms/ObjCARC/
H A DObjCARCContract.cpp617 Instruction *Replacement = Inst; in run() local
623 if (Replacement->getType() != UseTy) { in run()
634 Replacement = in run()
635 new BitCastInst(Replacement, UseTy, "", &InsertBB->back()); in run()
648 PHI->setIncomingValue(i, Replacement); in run()
651 if (Replacement->getType() != UseTy) in run()
652 Replacement = new BitCastInst(Replacement, UseTy, "", in run()
654 U.set(Replacement); in run()
/freebsd/contrib/llvm-project/clang/include/clang/AST/
H A DTemplateName.h376 TemplateName Replacement; variable
379 SubstTemplateTemplateParmStorage(TemplateName Replacement, in SubstTemplateTemplateParmStorage() argument
384 Replacement(Replacement), AssociatedDecl(AssociatedDecl) { in SubstTemplateTemplateParmStorage()
404 TemplateName getReplacement() const { return Replacement; } in getReplacement()
408 static void Profile(llvm::FoldingSetNodeID &ID, TemplateName Replacement,
/freebsd/contrib/llvm-project/llvm/lib/CodeGen/
H A DReplaceWithVeclib.cpp92 auto *Replacement = IRBuilder.CreateCall(TLIVecFunc, Args, OpBundles); in replaceWithTLIFunction() local
93 I.replaceAllUsesWith(Replacement); in replaceWithTLIFunction()
95 if (isa<FPMathOperator>(Replacement)) in replaceWithTLIFunction()
96 Replacement->copyFastMathFlags(&I); in replaceWithTLIFunction()
H A DInterleavedAccessPass.cpp465 for (auto &Replacement : ReplacementMap) { in tryReplaceExtracts() local
466 auto *Extract = Replacement.first; in tryReplaceExtracts()
467 auto *Vector = Replacement.second.first; in tryReplaceExtracts()
468 auto Index = Replacement.second.second; in tryReplaceExtracts()
/freebsd/contrib/llvm-project/clang/lib/Format/
H A DObjCPropertyAttributeOrderFixer.cpp150 auto Replacement = tooling::Replacement(SourceMgr, Range, NewText); in sortPropertyAttributes() local
151 auto Err = Fixes.add(Replacement); in sortPropertyAttributes()
/freebsd/contrib/llvm-project/llvm/lib/Target/BPF/
H A DBPFCheckAndAdjustIR.cpp290 Value *Replacement; in sinkMinMaxInBB() local
296 Replacement = Builder.CreateLogicalAnd(LHS, RHS); in sinkMinMaxInBB()
300 Replacement = Builder.CreateLogicalOr(LHS, RHS); in sinkMinMaxInBB()
302 ICmp->replaceAllUsesWith(Replacement); in sinkMinMaxInBB()
/freebsd/contrib/llvm-project/llvm/lib/Transforms/Utils/
H A DFunctionImportUtils.cpp344 auto Replacement = RenamedComdats.find(C); in processGlobalsForThinLTO() local
345 if (Replacement != RenamedComdats.end()) in processGlobalsForThinLTO()
346 GO.setComdat(Replacement->second); in processGlobalsForThinLTO()
/freebsd/contrib/llvm-project/llvm/include/llvm/Support/
H A DSourceMgr.h262 SMFixIt(SMRange R, const Twine &Replacement);
264 SMFixIt(SMLoc Loc, const Twine &Replacement) in SMFixIt() argument
265 : SMFixIt(SMRange(Loc, Loc), Replacement) {} in SMFixIt()
/freebsd/contrib/llvm-project/clang/lib/Sema/
H A DSemaAvailability.cpp504 StringRef Replacement; in DoEmitAvailabilityWarning() local
506 Replacement = AL->getReplacement(); in DoEmitAvailabilityWarning()
508 Replacement = AL->getReplacement(); in DoEmitAvailabilityWarning()
511 if (!Replacement.empty()) in DoEmitAvailabilityWarning()
519 Replacement, SelectorSlotNames, S.getLangOpts()); in DoEmitAvailabilityWarning()
533 FixIts.push_back(FixItHint::CreateReplacement(UseRange, Replacement)); in DoEmitAvailabilityWarning()
535 FixIts.push_back(FixItHint::CreateReplacement(UseRange, Replacement)); in DoEmitAvailabilityWarning()
/freebsd/contrib/llvm-project/clang/include/clang-c/
H A DRewrite.h38 const char *Replacement);
/freebsd/contrib/llvm-project/clang/lib/AST/
H A DTemplateName.cpp57 Profile(ID, Replacement, getAssociatedDecl(), getIndex(), getPackIndex()); in Profile()
61 llvm::FoldingSetNodeID &ID, TemplateName Replacement, Decl *AssociatedDecl, in Profile() argument
63 Replacement.Profile(ID); in Profile()

12345