Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,7 @@ private async ValueTask ProcessQueueAsync(CancellationToken cancellationToken)
return;
}

// Currently only project analyzers show in Solution Explorer, so isHostAnalyzer is always false.
var newDiagnosticItems = GenerateDiagnosticItems(project, analyzerReference, isHostAnalyzer: false);
var newDiagnosticItems = GenerateDiagnosticItems(project, analyzerReference);
var newSourceGeneratorItems = await GenerateSourceGeneratorItemsAsync(
project, analyzerReference).ConfigureAwait(false);

Expand All @@ -143,8 +142,7 @@ private async ValueTask ProcessQueueAsync(CancellationToken cancellationToken)

ImmutableArray<BaseItem> GenerateDiagnosticItems(
Project project,
AnalyzerReference analyzerReference,
bool isHostAnalyzer)
AnalyzerReference analyzerReference)
{
var generalDiagnosticOption = project.CompilationOptions!.GeneralDiagnosticOption;
var specificDiagnosticOptions = project.CompilationOptions!.SpecificDiagnosticOptions;
Expand All @@ -160,7 +158,7 @@ ImmutableArray<BaseItem> GenerateDiagnosticItems(
var selectedDiagnostic = g.OrderBy(d => d, s_comparer).First();
var effectiveSeverity = selectedDiagnostic.GetEffectiveSeverity(
project.CompilationOptions!,
isHostAnalyzer ? analyzerConfigOptions?.ConfigOptionsWithFallback : analyzerConfigOptions?.ConfigOptionsWithoutFallback,
analyzerConfigOptions?.ConfigOptionsWithoutFallback,
analyzerConfigOptions?.TreeOptions);
return (BaseItem)new DiagnosticItem(project.Id, analyzerReference, selectedDiagnostic, effectiveSeverity, CommandHandler);
});
Expand Down
Loading