Home
last modified time | relevance | path

Searched refs:Fix (Results 1 – 25 of 131) sorted by relevance

123456

/llvm-project-15.0.7/clang/unittests/Tooling/
H A DDiagnosticsYamlTest.cpp25 const std::string &FilePath, const StringMap<Replacements> &Fix, in makeMessage() argument
31 DiagMessage.Fix = Fix; in makeMessage()
49 const StringMap<Replacements> &Fix, in makeDiagnostic() argument
53 makeMessage(Message, FileOffset, FilePath, Fix, Ranges), {}, in makeDiagnostic()
166 auto getFixes = [](const StringMap<Replacements> &Fix) { in TEST() argument
168 for (auto &Replacements : Fix) { in TEST()
181 std::vector<Replacement> Fixes1 = getFixes(D1.Message.Fix); in TEST()
194 std::vector<Replacement> Fixes2 = getFixes(D2.Message.Fix); in TEST()
217 std::vector<Replacement> Fixes3 = getFixes(D3.Message.Fix); in TEST()
/llvm-project-15.0.7/clang-tools-extra/clangd/unittests/
H A DDiagnosticsTests.cpp80 MATCHER_P3(Fix, Range, Replacement, Message,
104 MATCHER_P(equalToFix, Fix, "LSP fix " + llvm::to_string(Fix)) {
105 if (arg.Message != Fix.Message)
107 if (arg.Edits.size() != Fix.Edits.size())
110 if (arg.Edits[I].range != Fix.Edits[I].range ||
660 ElementsAre(withFix(Fix( in TEST()
753 clangd::Fix ExpectedAFix; in TEST()
762 clangd::Fix ExpectedBFix; in TEST()
768 clangd::Fix ExpectedCFix; in TEST()
776 clangd::Fix ExpectedDFix; in TEST()
[all …]
/llvm-project-15.0.7/clang-tools-extra/clangd/
H A DIncludeFixer.h42 std::vector<Fix> fix(DiagnosticsEngine::Level DiagLevel,
52 std::vector<Fix> fixIncompleteType(const Type &T) const;
55 std::vector<Fix> fixesForSymbols(const SymbolSlab &Syms) const;
57 llvm::Optional<Fix> insertHeader(llvm::StringRef Name,
73 std::vector<Fix> fixUnresolvedName() const;
H A DDiagnostics.h81 struct Fix { struct
87 llvm::raw_ostream &operator<<(llvm::raw_ostream &OS, const Fix &F); argument
107 std::vector<Fix> Fixes;
121 llvm::function_ref<void(clangd::Diagnostic, llvm::ArrayRef<Fix>)> OutFn);
124 CodeAction toCodeAction(const Fix &D, const URIForFile &File);
150 using DiagFixer = std::function<std::vector<Fix>(DiagnosticsEngine::Level,
H A DIncludeFixer.cpp65 std::vector<Fix> only(llvm::Optional<Fix> F) { in only()
73 std::vector<Fix> IncludeFixer::fix(DiagnosticsEngine::Level DiagLevel, in fix()
251 llvm::Optional<Fix> IncludeFixer::insertHeader(llvm::StringRef Spelled, in insertHeader()
253 Fix F; in insertHeader()
268 std::vector<Fix> IncludeFixer::fixIncompleteType(const Type &T) const { in fixIncompleteType()
285 std::vector<Fix> Fixes; in fixIncompleteType()
313 std::vector<Fix> Fixes; in fixesForSymbols()
324 if (auto Fix = in fixesForSymbols() local
326 Fixes.push_back(std::move(*Fix)); in fixesForSymbols()
547 std::vector<Fix> IncludeFixer::fixUnresolvedName() const { in fixUnresolvedName()
[all …]
H A DDiagnostics.cpp391 llvm::raw_ostream &operator<<(llvm::raw_ostream &OS, const Fix &F) { in operator <<()
415 for (auto &Fix : D.Fixes) { in operator <<() local
416 OS << Sep << Fix; in operator <<()
424 CodeAction toCodeAction(const Fix &F, const URIForFile &File) { in toCodeAction()
461 llvm::function_ref<void(clangd::Diagnostic, llvm::ArrayRef<Fix>)> OutFn) { in toLSPDiags()
502 for (const auto &Fix : D.Fixes) in toLSPDiags() local
503 Main.codeActions->push_back(toCodeAction(Fix, File)); in toLSPDiags()
539 OutFn(std::move(Res), llvm::ArrayRef<Fix>()); in toLSPDiags()
602 for (auto &Fix : Diag.Fixes) in take() local
603 CleanMessage(Fix.Message); in take()
[all …]
/llvm-project-15.0.7/clang/lib/Tooling/Core/
H A DDiagnostic.cpp61 if (!D.Message.Fix.empty()) in selectFirstFix()
62 return &D.Message.Fix; in selectFirstFix()
64 return !D.Fix.empty(); in selectFirstFix()
67 return &Iter->Fix; in selectFirstFix()
/llvm-project-15.0.7/clang/include/clang/Tooling/
H A DDiagnosticsYaml.h44 for (auto &Replacements : M.Fix) { in LLVM_YAML_IS_SEQUENCE_VECTOR()
48 for (auto &Fix : Fixes) { in LLVM_YAML_IS_SEQUENCE_VECTOR()
49 llvm::Error Err = M.Fix[Fix.getFilePath()].add(Fix); in LLVM_YAML_IS_SEQUENCE_VECTOR()
/llvm-project-15.0.7/clang-tools-extra/clang-tidy/cppcoreguidelines/
H A DVirtualClassDestructorCheck.cpp192 FixItHint Fix; in check() local
196 Fix = FixItHint::CreateInsertion(Destructor->getLocation(), "virtual "); in check()
202 Fix = FixItHint::CreateRemoval(*MaybeRange); in check()
205 Fix = generateUserDeclaredDestructor(*MatchedClassOrStruct, in check()
216 << ProtectedAndVirtual << Fix; in check()
/llvm-project-15.0.7/clang-tools-extra/clang-tidy/readability/
H A DNamespaceCommentCheck.cpp185 std::string Fix(SpacesBeforeComments, ' '); in check() local
186 Fix.append("// namespace"); in check()
188 Fix.append(" ").append(*NamespaceNameAsWritten); in check()
190 Fix.append("\n"); in check()
201 Fix); in check()
/llvm-project-15.0.7/clang-tools-extra/clang-tidy/modernize/
H A DDeprecatedIosBaseAliasesCheck.cpp53 bool Fix = Replacement && !TL->getType()->isDependentType(); in check() local
56 Fix = false; in check()
67 if (Fix) in check()
/llvm-project-15.0.7/clang-tools-extra/clang-tidy/performance/
H A DForRangeCopyCheck.cpp94 if (llvm::Optional<FixItHint> Fix = utils::fixit::addQualifierToVarDecl( in handleConstValueCopy() local
96 Diagnostic << *Fix; in handleConstValueCopy()
125 if (llvm::Optional<FixItHint> Fix = utils::fixit::addQualifierToVarDecl( in handleCopyIsOnlyConstReferenced() local
127 Diag << *Fix << utils::fixit::changeVarDeclToReference(LoopVar, Context); in handleCopyIsOnlyConstReferenced()
/llvm-project-15.0.7/clang-tools-extra/test/clang-apply-replacements/Inputs/ignore-conflict/
H A Dfile1.yaml6 Message: Fix
16 Message: Fix
/llvm-project-15.0.7/clang-tools-extra/clang-tidy/
H A DClangTidyDiagnosticConsumer.cpp125 DiagWithFix->Fix[Replacement.getFilePath()].add(Replacement); in emitCodeContext()
326 if (!Diagnostic.Message.Fix.empty()) in getFixIt()
327 return &Diagnostic.Message.Fix; in getFixIt()
332 if (!Note.Fix.empty()) { in getFixIt()
336 Result = &Note.Fix; in getFixIt()
641 if (const auto *Fix = getFixIt(Error, GetFixesFromNotes)) in removeIncompatibleErrors() local
643 &Error, const_cast<llvm::StringMap<tooling::Replacements> *>(Fix)); in removeIncompatibleErrors()
765 Error.Message.Fix; in removeDuplicatedDiagnosticsOfAliasCheckers()
767 (*Inserted.first)->Message.Fix; in removeDuplicatedDiagnosticsOfAliasCheckers()
772 ExistingError.Message.Fix.clear(); in removeDuplicatedDiagnosticsOfAliasCheckers()
H A DClangTidy.cpp182 reportFix(Diag, Error.Message.Fix); in reportDiagnostic()
184 for (auto Fix : FixLocations) { in reportDiagnostic() local
185 Diags.Report(Fix.first, Fix.second ? diag::note_fixit_applied in reportDiagnostic()
257 const llvm::StringMap<Replacements> &Fix) { in reportFix() argument
258 for (const auto &FileAndReplacements : Fix) { in reportFix()
280 reportFix(Diag, Message.Fix); in reportNote()
586 ClangTidyContext &Context, FixBehaviour Fix, in handleErrors() argument
589 ErrorReporter Reporter(Context, Fix, std::move(BaseFS)); in handleErrors()
/llvm-project-15.0.7/polly/lib/External/isl/imath/
H A DChangeLog410 544687d Fix the spelling of mp_error_string in doc.md.
417 15ba02a Fix warnings for signed/unsigned comparisons.
427 389a1be bug: Fix a memory leak in test_meta.
428 8fb98f7 bug: Fix a use of an uninitalized pointer.
432 cebce44 bug: Fix various dead assignments.
434 eebfb85 Fix some more comparison-sign mismatches.
445 2a41bae Fix DLL loading.
449 6c6fdd8 Fix a vacuously meaningless comparison.
469 1dab081 Fix the spelling of __abs__ in imath.py.
479 0c5cec9 gmp_compat: Fix lvalue uses of MP_USED.
[all …]
/llvm-project-15.0.7/clang-tools-extra/unittests/clang-tidy/
H A DOverlappingReplacementsTest.cpp345 const char Fix[] = in TEST() local
352 EXPECT_EQ(Fix, Res); in TEST()
354 EXPECT_EQ(Fix, Res); in TEST()
/llvm-project-15.0.7/clang/lib/Format/
H A DQualifierAlignmentFixer.cpp92 for (const tooling::Replacement &Fix : Fixes) { in analyze() local
93 StringRef OriginalCode = Code.substr(Fix.getOffset(), Fix.getLength()); in analyze()
95 if (!OriginalCode.equals(Fix.getReplacementText())) { in analyze()
96 auto Err = NonNoOpFixes.add(Fix); in analyze()
/llvm-project-15.0.7/clang-tools-extra/test/clang-apply-replacements/Inputs/crlf/
H A Dfile1.yaml6 Message: Fix
/llvm-project-15.0.7/clang-tools-extra/test/clang-apply-replacements/Inputs/format/
H A Dno.yaml6 Message: Fix
/llvm-project-15.0.7/clang-tools-extra/test/clang-apply-replacements/Inputs/identical/
H A Dfile1.yaml6 Message: Fix
H A Dfile2.yaml6 Message: Fix
/llvm-project-15.0.7/clang-tools-extra/test/clang-apply-replacements/Inputs/conflict/
H A Dfile3.yaml6 Message: Fix
/llvm-project-15.0.7/clang-tools-extra/test/clang-apply-replacements/Inputs/relative-paths/
H A Dfile2.yaml7 Message: Fix
/llvm-project-15.0.7/clang-tools-extra/test/clang-apply-replacements/Inputs/basic/
H A Dfile2.yaml6 Message: Fix

123456