Home
last modified time | relevance | path

Searched refs:FixItHint (Results 1 – 25 of 303) sorted by relevance

12345678910>>...13

/external/llvm-project/clang/unittests/Tooling/
DFixItTest.cpp84 FixItHint Hint = createRemoval(*CE); in TEST()
90 FixItHint Hint0 = createRemoval(*P0); in TEST()
96 FixItHint Hint1 = createRemoval(*P1); in TEST()
105 FixItHint Hint0 = createRemoval(*P0); in TEST()
109 FixItHint Hint1 = createRemoval(*P1); in TEST()
119 FixItHint Hint = createRemoval(*CE); in TEST()
125 FixItHint Hint0 = createRemoval(*P0); in TEST()
134 FixItHint Hint1 = createRemoval(*P1); in TEST()
146 FixItHint Hint = createRemoval(*CE); in TEST()
164 FixItHint Hint0 = createReplacement(*P0, *P1, *Context); in TEST()
[all …]
/external/clang/unittests/Tooling/
DFixItTest.cpp85 FixItHint Hint = createRemoval(*CE); in TEST()
91 FixItHint Hint0 = createRemoval(*P0); in TEST()
97 FixItHint Hint1 = createRemoval(*P1); in TEST()
106 FixItHint Hint0 = createRemoval(*P0); in TEST()
110 FixItHint Hint1 = createRemoval(*P1); in TEST()
120 FixItHint Hint = createRemoval(*CE); in TEST()
126 FixItHint Hint0 = createRemoval(*P0); in TEST()
135 FixItHint Hint1 = createRemoval(*P1); in TEST()
147 FixItHint Hint = createRemoval(*CE); in TEST()
165 FixItHint Hint0 = createReplacement(*P0, *P1, *Context); in TEST()
[all …]
/external/llvm-project/clang/include/clang/Tooling/
DFixIt.h56 template <typename T> FixItHint createRemoval(const T &Node) { in createRemoval()
57 return FixItHint::CreateRemoval(internal::getSourceRange(Node)); in createRemoval()
62 FixItHint createReplacement(const D &Destination, const S &Source, in createReplacement()
64 return FixItHint::CreateReplacement(internal::getSourceRange(Destination), in createReplacement()
70 FixItHint createReplacement(const D &Destination, StringRef Source) { in createReplacement()
71 return FixItHint::CreateReplacement(internal::getSourceRange(Destination), in createReplacement()
/external/llvm-project/clang-tools-extra/clang-tidy/cppcoreguidelines/
DPreferMemberInitializerCheck.cpp162 Diag << FixItHint::CreateInsertion(FieldEnd, in check()
164 << FixItHint::CreateInsertionFromRange( in check()
167 << FixItHint::CreateInsertion(FieldEnd, UseAssignment ? "" : "}"); in check()
176 Diag << FixItHint::CreateRemoval(StmtRange); in check()
196 Diag << FixItHint::CreateInsertion(InsertPos, " : "); in check()
216 Diag << FixItHint::CreateInsertion(InsertPos, ", "); in check()
221 Diag << FixItHint::CreateInsertion(InsertPos, Field->getName()) in check()
222 << FixItHint::CreateInsertion(InsertPos, "(") in check()
223 << FixItHint::CreateInsertionFromRange( in check()
226 << FixItHint::CreateInsertion(InsertPos, ")"); in check()
[all …]
/external/llvm-project/clang-tools-extra/clang-tidy/modernize/
DMakeSmartPtrCheck.cpp185 Diag << FixItHint::CreateInsertion( in checkConstruct()
192 Diag << FixItHint::CreateReplacement( in checkConstruct()
200 Diag << FixItHint::CreateReplacement( in checkConstruct()
204 Diag << FixItHint::CreateReplacement( in checkConstruct()
248 Diag << FixItHint::CreateReplacement( in checkReset()
255 Diag << FixItHint::CreateInsertion(ExprStart, "*"); in checkReset()
327 Diag << FixItHint::CreateRemoval(SourceRange(NewStart, NewEnd)); in replaceNew()
331 Diag << FixItHint::CreateReplacement(SourceRange(NewStart, NewEnd), in replaceNew()
360 Diag << FixItHint::CreateRemoval( in replaceNew()
362 Diag << FixItHint::CreateRemoval(SourceRange(InitRange.getEnd(), NewEnd)); in replaceNew()
[all …]
DReplaceRandomShuffleCheck.cpp70 DiagL << FixItHint::CreateReplacement( in check()
78 DiagL << FixItHint::CreateInsertion( in check()
92 Diag << FixItHint::CreateRemoval(MatchedDecl->getSourceRange()); in check()
93 Diag << FixItHint::CreateInsertion(MatchedDecl->getBeginLoc(), NewName); in check()
/external/llvm-project/clang-tools-extra/clang-tidy/google/
DGlobalVariableDeclarationCheck.cpp28 FixItHint generateFixItHint(const VarDecl *Decl, bool IsConst) { in generateFixItHint()
32 return FixItHint(); in generateFixItHint()
41 return FixItHint(); in generateFixItHint()
48 return FixItHint(); in generateFixItHint()
55 return FixItHint::CreateReplacement( in generateFixItHint()
DFunctionNamingCheck.cpp50 FixItHint generateFixItHint(const FunctionDecl *Decl) { in generateFixItHint()
55 return FixItHint(); in generateFixItHint()
82 return FixItHint::CreateReplacement( in generateFixItHint()
86 return FixItHint(); in generateFixItHint()
/external/llvm-project/clang-tools-extra/clang-tidy/objc/
DNSInvocationArgumentLifetimeCheck.cpp55 static llvm::Optional<FixItHint>
64 return FixItHint::CreateReplacement(SourceRange(Begin, End), in fixItHintReplacementForOwnershipString()
68 static llvm::Optional<FixItHint>
88 if (llvm::Optional<FixItHint> Hint = in fixItHintForVarDecl()
92 if (llvm::Optional<FixItHint> Hint = fixItHintReplacementForOwnershipString( in fixItHintForVarDecl()
96 return FixItHint::CreateInsertion(Range.getBegin(), "__unsafe_unretained "); in fixItHintForVarDecl()
/external/llvm-project/clang-tools-extra/clang-tidy/bugprone/
DRedundantBranchConditionCheck.cpp116 Diag << FixItHint::CreateRemoval( in check()
118 << FixItHint::CreateInsertion(AfterOtherSide, ";") in check()
119 << FixItHint::CreateRemoval( in check()
122 Diag << FixItHint::CreateRemoval( in check()
128 Diag << FixItHint::CreateRemoval( in check()
141 Diag << FixItHint::CreateRemoval(CharSourceRange::getTokenRange( in check()
148 Diag << FixItHint::CreateRemoval(CharSourceRange::getTokenRange( in check()
DStringIntegerAssignmentCheck.cpp163 Diag << FixItHint::CreateInsertion(Loc, IsWideCharType ? "L'" : "'") in check()
164 << FixItHint::CreateInsertion(EndLoc, "'"); in check()
168 Diag << FixItHint::CreateInsertion(Loc, IsWideCharType ? "L\"" : "\"") in check()
169 << FixItHint::CreateInsertion(EndLoc, "\""); in check()
174 Diag << FixItHint::CreateInsertion(Loc, IsWideCharType ? "std::to_wstring(" in check()
176 << FixItHint::CreateInsertion(EndLoc, ")"); in check()
/external/llvm-project/clang-tools-extra/clang-tidy/utils/
DFixItHintUtils.cpp19 FixItHint changeVarDeclToReference(const VarDecl &Var, ASTContext &Context) { in changeVarDeclToReference()
27 return FixItHint::CreateInsertion(AmpLocation, "&"); in changeVarDeclToReference()
65 static Optional<FixItHint> fixIfNotDangerous(SourceLocation Loc, in fixIfNotDangerous()
69 return FixItHint::CreateInsertion(Loc, Text); in fixIfNotDangerous()
81 static Optional<FixItHint> changeValue(const VarDecl &Var, in changeValue()
101 static Optional<FixItHint> changePointerItself(const VarDecl &Var, in changePointerItself()
114 static Optional<FixItHint>
165 static Optional<FixItHint>
184 Optional<FixItHint> addQualifierToVarDecl(const VarDecl &Var, in addQualifierToVarDecl()
DHeaderGuard.cpp102 std::vector<FixItHint> FixIts; in EndOfMainFile()
165 std::vector<FixItHint> &FixIts) { in checkHeaderGuardDefinition()
174 FixIts.push_back(FixItHint::CreateReplacement( in checkHeaderGuardDefinition()
178 FixIts.push_back(FixItHint::CreateReplacement( in checkHeaderGuardDefinition()
191 std::vector<FixItHint> &FixIts) { in checkEndifComment()
194 FixIts.push_back(FixItHint::CreateReplacement( in checkEndifComment()
242 << FixItHint::CreateInsertion( in checkGuardlessHeaders()
244 << FixItHint::CreateInsertion( in checkGuardlessHeaders()
DIncludeSorter.cpp153 Optional<FixItHint> IncludeSorter::CreateIncludeInsertion(StringRef FileName, in CreateIncludeInsertion()
169 return FixItHint::CreateInsertion( in CreateIncludeInsertion()
180 return FixItHint::CreateInsertion(Location.getBegin(), IncludeStmt); in CreateIncludeInsertion()
189 return FixItHint::CreateInsertion(LastIncludeLocation.getEnd(), in CreateIncludeInsertion()
214 return FixItHint::CreateInsertion(LastIncludeLocation.getEnd(), in CreateIncludeInsertion()
221 return FixItHint::CreateInsertion(FirstIncludeLocation.getBegin(), in CreateIncludeInsertion()
/external/clang/include/clang/Tooling/
DFixIt.h56 template <typename T> FixItHint createRemoval(const T &Node) { in createRemoval()
57 return FixItHint::CreateRemoval(internal::getSourceRange(Node)); in createRemoval()
62 FixItHint createReplacement(const D &Destination, const S &Source, in createReplacement()
64 return FixItHint::CreateReplacement(internal::getSourceRange(Destination), in createReplacement()
/external/clang/include/clang/Basic/
DDiagnostic.h52 class FixItHint {
70 FixItHint() : BeforePreviousInsertions(false) { } in FixItHint() function
78 static FixItHint CreateInsertion(SourceLocation InsertionLoc,
81 FixItHint Hint;
91 static FixItHint CreateInsertionFromRange(SourceLocation InsertionLoc,
94 FixItHint Hint;
104 static FixItHint CreateRemoval(CharSourceRange RemoveRange) { in CreateRemoval()
105 FixItHint Hint; in CreateRemoval()
109 static FixItHint CreateRemoval(SourceRange RemoveRange) { in CreateRemoval()
115 static FixItHint CreateReplacement(CharSourceRange RemoveRange, in CreateReplacement()
[all …]
/external/clang/lib/Sema/
DSemaFixItUtils.cpp109 Hints.push_back(FixItHint::CreateRemoval( in tryToFixConversion()
113 Hints.push_back(FixItHint::CreateInsertion(Begin, "*(")); in tryToFixConversion()
114 Hints.push_back(FixItHint::CreateInsertion(End, ")")); in tryToFixConversion()
116 Hints.push_back(FixItHint::CreateInsertion(Begin, "*")); in tryToFixConversion()
143 Hints.push_back(FixItHint::CreateRemoval( in tryToFixConversion()
147 Hints.push_back(FixItHint::CreateInsertion(Begin, "&(")); in tryToFixConversion()
148 Hints.push_back(FixItHint::CreateInsertion(End, ")")); in tryToFixConversion()
150 Hints.push_back(FixItHint::CreateInsertion(Begin, "&")); in tryToFixConversion()
/external/llvm-project/clang/lib/Sema/
DSemaFixItUtils.cpp108 Hints.push_back(FixItHint::CreateRemoval( in tryToFixConversion()
112 Hints.push_back(FixItHint::CreateInsertion(Begin, "*(")); in tryToFixConversion()
113 Hints.push_back(FixItHint::CreateInsertion(End, ")")); in tryToFixConversion()
115 Hints.push_back(FixItHint::CreateInsertion(Begin, "*")); in tryToFixConversion()
142 Hints.push_back(FixItHint::CreateRemoval( in tryToFixConversion()
146 Hints.push_back(FixItHint::CreateInsertion(Begin, "&(")); in tryToFixConversion()
147 Hints.push_back(FixItHint::CreateInsertion(End, ")")); in tryToFixConversion()
149 Hints.push_back(FixItHint::CreateInsertion(Begin, "&")); in tryToFixConversion()
/external/llvm-project/clang-tools-extra/clang-tidy/llvm/
DTwineLocalCheck.cpp53 Diag << FixItHint::CreateReplacement(TypeRange, "std::string") in check()
54 << FixItHint::CreateInsertion(VD->getInit()->getBeginLoc(), "(") in check()
55 << FixItHint::CreateInsertion(EndLoc, ").str()"); in check()
58 Diag << FixItHint::CreateReplacement( in check()
/external/llvm-project/clang/include/clang/Basic/
DDiagnostic.h70 class FixItHint {
88 FixItHint() = default;
96 static FixItHint CreateInsertion(SourceLocation InsertionLoc,
99 FixItHint Hint;
109 static FixItHint CreateInsertionFromRange(SourceLocation InsertionLoc,
112 FixItHint Hint;
122 static FixItHint CreateRemoval(CharSourceRange RemoveRange) { in CreateRemoval()
123 FixItHint Hint; in CreateRemoval()
127 static FixItHint CreateRemoval(SourceRange RemoveRange) { in CreateRemoval()
133 static FixItHint CreateReplacement(CharSourceRange RemoveRange, in CreateReplacement()
[all …]
/external/clang/lib/Frontend/
DDiagnosticRenderer.cpp35 SmallVectorImpl<FixItHint> &MergedFixits;
38 FixitReceiver(SmallVectorImpl<FixItHint> &MergedFixits) in FixitReceiver()
41 MergedFixits.push_back(FixItHint::CreateInsertion(loc, text)); in insert()
44 MergedFixits.push_back(FixItHint::CreateReplacement(range, text)); in replace()
50 static void mergeFixits(ArrayRef<FixItHint> FixItHints, in mergeFixits()
52 SmallVectorImpl<FixItHint> &MergedFixits) { in mergeFixits()
54 for (ArrayRef<FixItHint>::const_iterator in mergeFixits()
56 const FixItHint &Hint = *I; in mergeFixits()
85 ArrayRef<FixItHint> FixItHints, in emitDiagnostic()
100 SmallVector<FixItHint, 8> MergedFixits; in emitDiagnostic()
[all …]
/external/llvm-project/clang-tools-extra/clang-tidy/abseil/
DDurationDivisionCheck.cpp43 << FixItHint::CreateInsertion(OpCall->getBeginLoc(), in check()
45 << FixItHint::CreateReplacement( in check()
48 << FixItHint::CreateInsertion( in check()
DDurationUnnecessaryConversionCheck.cpp83 FixItHint Hint; in check()
91 Hint = FixItHint::CreateReplacement( in check()
100 Hint = FixItHint::CreateReplacement( in check()
107 Hint = FixItHint::CreateReplacement( in check()
/external/llvm-project/clang-tools-extra/clang-tidy/misc/
DStaticAssertCheck.cpp114 SmallVector<FixItHint, 4> FixItHints; in check()
119 FixItHint::CreateReplacement(SourceRange(AssertLoc), "static_assert")); in check()
123 FixItHints.push_back(FixItHint::CreateRemoval( in check()
125 FixItHints.push_back(FixItHint::CreateRemoval( in check()
131 FixItHint::CreateInsertion(LastParenLoc, StaticAssertMSG)); in check()
/external/llvm-project/clang-tools-extra/clang-tidy/altera/
DStructPackAlignCheck.cpp99 << FixItHint::CreateInsertion(Struct->getEndLoc().getLocWithOffset(1), in check()
108 FixItHint FixIt; in check()
115 FixItHint::CreateReplacement(Attribute->getRange(), FixItString.str()); in check()
119 FixIt = FixItHint::CreateInsertion(Struct->getEndLoc().getLocWithOffset(1), in check()

12345678910>>...13