Skip to content

Commit

Permalink
GH-153 - adding missing sealed modifiers
Browse files Browse the repository at this point in the history
  • Loading branch information
tpodolak committed Oct 2, 2022
1 parent 9529446 commit 548872b
Show file tree
Hide file tree
Showing 17 changed files with 17 additions and 17 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ internal abstract class AbstractConstructorArgumentsForInterfaceCodeFixProvider
public override ImmutableArray<string> FixableDiagnosticIds { get; } =
ImmutableArray.Create(DiagnosticIdentifiers.SubstituteConstructorArgumentsForInterface);

public override Task RegisterCodeFixesAsync(CodeFixContext context)
public sealed override Task RegisterCodeFixesAsync(CodeFixContext context)
{
var codeAction = CodeAction.Create(
"Remove constructor arguments",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ internal abstract class AbstractInternalSetupSpecificationCodeFixProvider<TCompi

protected abstract string ReplaceModifierCodeFixTitle { get; }

public override async Task RegisterCodeFixesAsync(CodeFixContext context)
public sealed override async Task RegisterCodeFixesAsync(CodeFixContext context)
{
var root = await context.Document.GetSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
var invocationExpression = root.FindNode(context.Span, getInnermostNodeForTie: true);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ internal abstract class AbstractPartialSubstituteUsedForUnsupportedTypeCodeFixPr
public override ImmutableArray<string> FixableDiagnosticIds { get; } =
ImmutableArray.Create(DiagnosticIdentifiers.PartialSubstituteForUnsupportedType);

public override async Task RegisterCodeFixesAsync(CodeFixContext context)
public sealed override async Task RegisterCodeFixesAsync(CodeFixContext context)
{
var root = await context.Document.GetSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);
var syntaxNode = root.FindNode(context.Span, getInnermostNodeForTie: true);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ internal abstract class AbstractReceivedInReceivedInOrderCodeFixProvider : CodeF

public override ImmutableArray<string> FixableDiagnosticIds { get; } = ImmutableArray.Create(DiagnosticIdentifiers.ReceivedUsedInReceivedInOrder);

public override Task RegisterCodeFixesAsync(CodeFixContext context)
public sealed override Task RegisterCodeFixesAsync(CodeFixContext context)
{
var codeAction = CodeAction.Create(
"Remove redundant Received checks",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ protected AbstractSubstituteForInternalMemberCodeFixProvider(ISubstituteProxyAna
_substituteProxyAnalysis = substituteProxyAnalysis;
}

public override async Task RegisterCodeFixesAsync(CodeFixContext context)
public sealed override async Task RegisterCodeFixesAsync(CodeFixContext context)
{
var root = await context.Document.GetSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ protected AbstractSyncOverAsyncThrowsCodeFixProvider(ISubstitutionNodeFinder sub

public override FixAllProvider GetFixAllProvider() => WellKnownFixAllProviders.BatchFixer;

public override async Task RegisterCodeFixesAsync(CodeFixContext context)
public sealed override async Task RegisterCodeFixesAsync(CodeFixContext context)
{
var root = await context.Document.GetSyntaxRootAsync(context.CancellationToken).ConfigureAwait(false);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ protected AbstractCallInfoAnalyzer(

public override ImmutableArray<DiagnosticDescriptor> SupportedDiagnostics { get; }

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ protected AbstractConflictingArgumentAssignmentsAnalyzer(

public override ImmutableArray<DiagnosticDescriptor> SupportedDiagnostics { get; }

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ protected AbstractNonSubstitutableMemberArgumentMatcherAnalyzer(

public override ImmutableArray<DiagnosticDescriptor> SupportedDiagnostics { get; }

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ protected AbstractNonSubstitutableMemberReceivedAnalyzer(

protected override DiagnosticDescriptor NonVirtualSetupDescriptor { get; }

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationOperation, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ protected AbstractNonSubstitutableMemberWhenAnalyzer(

protected override DiagnosticDescriptor NonVirtualSetupDescriptor { get; }

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ protected AbstractReEntrantSetupAnalyzer(
SupportedDiagnostics = ImmutableArray.Create(DiagnosticDescriptorsProvider.ReEntrantSubstituteCall);
}

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ protected AbstractReceivedInReceivedInOrderAnalyzer(
SupportedDiagnostics = ImmutableArray.Create(diagnosticDescriptorsProvider.ReceivedUsedInReceivedInOrder);
}

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ protected AbstractSubstituteAnalyzer(

public override ImmutableArray<DiagnosticDescriptor> SupportedDiagnostics { get; }

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ protected AbstractSyncOverAsyncThrowsAnalyzer(

public override ImmutableArray<DiagnosticDescriptor> SupportedDiagnostics { get; }

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ protected AbstractUnusedReceivedAnalyzer(IDiagnosticDescriptorsProvider diagnost
private static readonly ImmutableHashSet<OperationKind> PossibleParents =
ImmutableHashSet.Create(OperationKind.PropertyReference, OperationKind.Invocation);

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ protected AbstractWithAnyArgsArgumentMatcherAnalyzer(

public override ImmutableArray<DiagnosticDescriptor> SupportedDiagnostics { get; }

protected override void InitializeAnalyzer(AnalysisContext context)
protected sealed override void InitializeAnalyzer(AnalysisContext context)
{
context.RegisterOperationAction(_analyzeInvocationAction, OperationKind.Invocation);
}
Expand Down

0 comments on commit 548872b

Please sign in to comment.