Skip to content

Commit 58feafc

Browse files
committed
[Migrator] Remove unused MigratorOptions in FixitApplyDiagnosticConsumer
This isn't needed right now.
1 parent c719818 commit 58feafc

File tree

3 files changed

+3
-11
lines changed

3 files changed

+3
-11
lines changed

include/swift/Migrator/FixitApplyDiagnosticConsumer.h

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,6 @@ class FixitApplyDiagnosticConsumer final
3434
: public DiagnosticConsumer, public FixitFilter {
3535
clang::RewriteBuffer RewriteBuf;
3636

37-
/// The Migrator options collected by the Swift CompilerInvocation,
38-
/// used to drive decisions about which fix-its to apply.
39-
const MigratorOptions &MigratorOpts;
40-
4137
/// The entire text of the input file.
4238
const StringRef Text;
4339

@@ -50,8 +46,7 @@ class FixitApplyDiagnosticConsumer final
5046
unsigned NumFixitsApplied;
5147

5248
public:
53-
FixitApplyDiagnosticConsumer(const MigratorOptions &MigratorOpts,
54-
const StringRef Text,
49+
FixitApplyDiagnosticConsumer(const StringRef Text,
5550
const StringRef BufferName);
5651

5752
/// Print the resulting text, applying the caught fix-its to the given

lib/Migrator/FixitApplyDiagnosticConsumer.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,9 @@ using namespace swift;
2121
using namespace swift::migrator;
2222

2323
FixitApplyDiagnosticConsumer::
24-
FixitApplyDiagnosticConsumer(const MigratorOptions &MigratorOpts,
25-
const StringRef Text,
24+
FixitApplyDiagnosticConsumer(const StringRef Text,
2625
const StringRef BufferName)
27-
: MigratorOpts(MigratorOpts),
28-
Text(Text), BufferName(BufferName), NumFixitsApplied(0) {
26+
: Text(Text), BufferName(BufferName), NumFixitsApplied(0) {
2927
RewriteBuf.Initialize(Text);
3028
}
3129

lib/Migrator/Migrator.cpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,6 @@ Migrator::performAFixItMigration() {
104104
}
105105

106106
FixitApplyDiagnosticConsumer FixitApplyConsumer {
107-
getMigratorOptions(),
108107
InputState->getInputText(),
109108
getInputFilename(),
110109
};

0 commit comments

Comments
 (0)