diff --git a/src/EditorFeatures/CSharpTest/Classification/SemanticClassifierTests.cs b/src/EditorFeatures/CSharpTest/Classification/SemanticClassifierTests.cs index 680f17bd3701f..d68fd335c8968 100644 --- a/src/EditorFeatures/CSharpTest/Classification/SemanticClassifierTests.cs +++ b/src/EditorFeatures/CSharpTest/Classification/SemanticClassifierTests.cs @@ -2608,13 +2608,13 @@ public async Task TestCreateWithBufferNotInWorkspace() WpfTestRunner.RequireWpfFact($"Creates an {nameof(IWpfTextView)} explicitly with an unrelated buffer"); using var disposableView = workspace.ExportProvider.GetExportedValue().CreateDisposableTextView(extraBuffer); var listenerProvider = workspace.ExportProvider.GetExportedValue(); - var globalOptionsService = workspace.ExportProvider.GetExportedValue(); + var globalOptions = workspace.ExportProvider.GetExportedValue(); var provider = new SemanticClassificationViewTaggerProvider( workspace.GetService(), workspace.GetService(), - listenerProvider, - globalOptionsService); + globalOptions, + listenerProvider); using var tagger = (IDisposable)provider.CreateTagger(disposableView.TextView, extraBuffer); using (var edit = extraBuffer.CreateEdit()) diff --git a/src/EditorFeatures/Core/Implementation/Classification/SemanticClassificationViewTaggerProvider.cs b/src/EditorFeatures/Core/Implementation/Classification/SemanticClassificationViewTaggerProvider.cs index 87d80ca3cf7e6..85b5fb1f4e261 100644 --- a/src/EditorFeatures/Core/Implementation/Classification/SemanticClassificationViewTaggerProvider.cs +++ b/src/EditorFeatures/Core/Implementation/Classification/SemanticClassificationViewTaggerProvider.cs @@ -38,7 +38,7 @@ namespace Microsoft.CodeAnalysis.Editor.Implementation.Classification internal partial class SemanticClassificationViewTaggerProvider : AsynchronousViewTaggerProvider { private readonly ClassificationTypeMap _typeMap; - private readonly IGlobalOptionService _globalOptionsService; + private readonly IGlobalOptionService _globalOptions; // We want to track text changes so that we can try to only reclassify a method body if // all edits were contained within one. @@ -55,7 +55,7 @@ public SemanticClassificationViewTaggerProvider( : base(threadingContext, globalOptions, listenerProvider.GetListener(FeatureAttribute.Classification)) { _typeMap = typeMap; - _globalOptionsService = globalOptionsService; + _globalOptions = globalOptions; } protected override TaggerDelay EventChangeDelay => TaggerDelay.Short; @@ -120,7 +120,7 @@ protected override Task ProduceTagsAsync( return Task.CompletedTask; // If the LSP semantic tokens feature flag is enabled, return nothing to prevent conflicts. - var isLspSemanticTokensEnabled = _globalOptionsService.GetOption(LspOptions.LspSemanticTokensFeatureFlag); + var isLspSemanticTokensEnabled = _globalOptions.GetOption(LspOptions.LspSemanticTokensFeatureFlag); if (isLspSemanticTokensEnabled) { return Task.CompletedTask; diff --git a/src/VisualStudio/Core/Def/Packaging/PackageInstallerServiceFactory.cs b/src/VisualStudio/Core/Def/Packaging/PackageInstallerServiceFactory.cs index c2b3103e60a79..3253218dd95a8 100644 --- a/src/VisualStudio/Core/Def/Packaging/PackageInstallerServiceFactory.cs +++ b/src/VisualStudio/Core/Def/Packaging/PackageInstallerServiceFactory.cs @@ -108,7 +108,7 @@ public PackageInstallerService( : base(threadingContext, workspace, globalOptions, - SymbolSearchOptions.Enabled, + SymbolSearchGlobalOptions.Enabled, SymbolSearchOptions.SuggestForTypesInReferenceAssemblies, SymbolSearchOptions.SuggestForTypesInNuGetPackages) { diff --git a/src/VisualStudio/Core/Def/SymbolSearch/VisualStudioSymbolSearchService.cs b/src/VisualStudio/Core/Def/SymbolSearch/VisualStudioSymbolSearchService.cs index 3766d742c2d38..d470c975da03a 100644 --- a/src/VisualStudio/Core/Def/SymbolSearch/VisualStudioSymbolSearchService.cs +++ b/src/VisualStudio/Core/Def/SymbolSearch/VisualStudioSymbolSearchService.cs @@ -56,7 +56,7 @@ public VisualStudioSymbolSearchService( VisualStudioWorkspaceImpl workspace, IGlobalOptionService globalOptions, VSShell.SVsServiceProvider serviceProvider) - : base(threadingContext, workspace, globalOptions, SymbolSearchOptions.Enabled, + : base(threadingContext, workspace, globalOptions, SymbolSearchGlobalOptions.Enabled, SymbolSearchOptions.SuggestForTypesInReferenceAssemblies, SymbolSearchOptions.SuggestForTypesInNuGetPackages) { _workspace = workspace; diff --git a/src/Workspaces/CoreTest/WorkspaceServiceTests/OptionServiceTests.cs b/src/Workspaces/CoreTest/WorkspaceServiceTests/OptionServiceTests.cs index 045ee0186d62e..a6c0a7df2396b 100644 --- a/src/Workspaces/CoreTest/WorkspaceServiceTests/OptionServiceTests.cs +++ b/src/Workspaces/CoreTest/WorkspaceServiceTests/OptionServiceTests.cs @@ -314,7 +314,7 @@ public void TestChangedTodoCommentOptions() using var workspace = new AdhocWorkspace(hostServices); var option = TodoCommentOptions.TokenList; - var provider = ((IMefHostExportProvider)hostServices).GetExportedValues().OfType().FirstOrDefault(); + var provider = ((IMefHostExportProvider)hostServices).GetExportedValues().OfType().FirstOrDefault(); var optionService = TestOptionService.GetService(workspace, provider); var optionSet = optionService.GetOptions(); var optionKey = new OptionKey(option); @@ -349,7 +349,7 @@ public void TestPersistedTodoCommentOptions() Assert.True(persister.TryFetch(option, out var persistedValue)); Assert.Equal(newOptionValue, persistedValue); - var provider = ((IMefHostExportProvider)hostServices).GetExportedValues().OfType().FirstOrDefault(); + var provider = ((IMefHostExportProvider)hostServices).GetExportedValues().OfType().FirstOrDefault(); var persisterProvider = new TestOptionService.TestOptionsPersisterProvider(persister); var optionService = TestOptionService.GetService(workspace, provider, persisterProvider); var optionSet = optionService.GetOptions();