diff --git a/src/EditorFeatures/Test/Diagnostics/DiagnosticAnalyzerServiceTests.cs b/src/EditorFeatures/Test/Diagnostics/DiagnosticAnalyzerServiceTests.cs index 1cdbde9790790..ecf379a69b6cd 100644 --- a/src/EditorFeatures/Test/Diagnostics/DiagnosticAnalyzerServiceTests.cs +++ b/src/EditorFeatures/Test/Diagnostics/DiagnosticAnalyzerServiceTests.cs @@ -162,11 +162,12 @@ public async Task TestDisabledByDefaultAnalyzerEnabledWithEditorConfig(bool enab if (enabledWithEditorconfig) { - var editorconfigText = @$" -[*.cs] -dotnet_diagnostic.{DisabledByDefaultAnalyzer.s_syntaxRule.Id}.severity = warning -dotnet_diagnostic.{DisabledByDefaultAnalyzer.s_semanticRule.Id}.severity = warning -dotnet_diagnostic.{DisabledByDefaultAnalyzer.s_compilationRule.Id}.severity = warning"; + var editorconfigText = $""" + [*.cs] + dotnet_diagnostic.{DisabledByDefaultAnalyzer.s_syntaxRule.Id}.severity = warning + dotnet_diagnostic.{DisabledByDefaultAnalyzer.s_semanticRule.Id}.severity = warning + dotnet_diagnostic.{DisabledByDefaultAnalyzer.s_compilationRule.Id}.severity = warning + """; project = project.AddAnalyzerConfigDocument(".editorconfig", filePath: "z:\\.editorconfig", text: SourceText.From(editorconfigText)).Project; } @@ -345,10 +346,10 @@ public async Task TestFullSolutionAnalysisForHiddenAnalyzers_SeverityInAnalyzerC // Escalating the analyzer to non-hidden effective severity through analyzer config options // ensures that analyzer executes in full solution analysis. - var analyzerConfigText = $@" -[*.cs] -dotnet_diagnostic.{NamedTypeAnalyzer.DiagnosticId}.severity = warning -"; + var analyzerConfigText = $""" + [*.cs] + dotnet_diagnostic.{NamedTypeAnalyzer.DiagnosticId}.severity = warning + """; project = project.AddAnalyzerConfigDocument( ".editorconfig", @@ -554,36 +555,36 @@ internal async Task TestRemoveUnnecessaryInlineSuppressionsAnalyzer(BackgroundAn string code; if (testPragma) { - code = $@" -#pragma warning disable {NamedTypeAnalyzer.DiagnosticId} // Unnecessary -#pragma warning disable CS0168 // Variable is declared but never used - Unnecessary - -#pragma warning disable {NamedTypeAnalyzer.DiagnosticId} // Necessary -class A -{{ - void M() - {{ -#pragma warning disable CS0168 // Variable is declared but never used - Necessary - int x; - }} -}} -"; + code = $$""" + #pragma warning disable {{NamedTypeAnalyzer.DiagnosticId}} // Unnecessary + #pragma warning disable CS0168 // Variable is declared but never used - Unnecessary + + #pragma warning disable {{NamedTypeAnalyzer.DiagnosticId}} // Necessary + class A + { + void M() + { + #pragma warning disable CS0168 // Variable is declared but never used - Necessary + int x; + } + } + """; } else { - code = $@" -[System.Diagnostics.CodeAnalysis.SuppressMessage(""Category1"", ""{NamedTypeAnalyzer.DiagnosticId}"")] // Necessary -class A -{{ - [System.Diagnostics.CodeAnalysis.SuppressMessage(""Category2"", ""{NamedTypeAnalyzer.DiagnosticId}"")] // Unnecessary - [System.Diagnostics.CodeAnalysis.SuppressMessage(""Category3"", ""CS0168"")] // Unnecessary - void M() - {{ -#pragma warning disable CS0168 // Variable is declared but never used - Necessary - int x; - }} -}} -"; + code = $$""" + [System.Diagnostics.CodeAnalysis.SuppressMessage("Category1", "{{NamedTypeAnalyzer.DiagnosticId}}")] // Necessary + class A + { + [System.Diagnostics.CodeAnalysis.SuppressMessage("Category2", "{{NamedTypeAnalyzer.DiagnosticId}}")] // Unnecessary + [System.Diagnostics.CodeAnalysis.SuppressMessage("Category3", "CS0168")] // Unnecessary + void M() + { + #pragma warning disable CS0168 // Variable is declared but never used - Necessary + int x; + } + } + """; } string[] files; @@ -605,7 +606,6 @@ void M() using var workspace = new EditorTestWorkspace(composition); workspace.GlobalOptions.SetGlobalOption(SolutionCrawlerOptionsStorage.BackgroundAnalysisScopeOption, LanguageNames.CSharp, analysisScope); - workspace.GlobalOptions.SetGlobalOption(SolutionCrawlerOptionsStorage.EnableDiagnosticsInSourceGeneratedFiles, isSourceGenerated); var compilerDiagnosticsScope = analysisScope.ToEquivalentCompilerDiagnosticsScope(); workspace.GlobalOptions.SetGlobalOption(SolutionCrawlerOptionsStorage.CompilerDiagnosticsScopeOption, LanguageNames.CSharp, compilerDiagnosticsScope); @@ -714,14 +714,15 @@ internal async Task TestOnlyRequiredAnalyzerExecutedDuringDiagnosticComputation( [CombinatorialData] public async Task TestFilterSpanOnContextAsync(FilterSpanTestAnalyzer.AnalysisKind kind) { - var source = @" -class B -{ - void M() - { - int x = 1; - } -}"; + var source = """ + class B + { + void M() + { + int x = 1; + } + } + """; var additionalText = @"This is an additional file!"; using var workspace = TestWorkspace.CreateCSharp(source); @@ -788,14 +789,15 @@ internal async Task TestCancellationDuringDiagnosticComputation_OutOfProc(Analyz // NOTE: Unfortunately, we cannot perform an end-to-end OutOfProc test, similar to the InProc test above because AnalyzerImageReference is not serializable. // So, we perform a very targeted test which directly uses the 'DiagnosticComputer' type that is used for all OutOfProc diagnostic computation. - var source = @" -class A -{ - void M() - { - int x = 0; - } -}"; + var source = """ + class A + { + void M() + { + int x = 0; + } + } + """; using var workspace = TestWorkspace.CreateCSharp(source); diff --git a/src/EditorFeatures/TestUtilities/Options/OptionSerializerTests.cs b/src/EditorFeatures/TestUtilities/Options/OptionSerializerTests.cs index affc07501af66..c520e8a12bcb8 100644 --- a/src/EditorFeatures/TestUtilities/Options/OptionSerializerTests.cs +++ b/src/EditorFeatures/TestUtilities/Options/OptionSerializerTests.cs @@ -27,7 +27,6 @@ public void SerializationAndDeserializationForNullableBool([CombinatorialValues( CompletionViewOptionsStorage.EnableArgumentCompletionSnippets, FeatureOnOffOptions.OfferRemoveUnusedReferences, InheritanceMarginOptionsStorage.ShowInheritanceMargin, - SolutionCrawlerOptionsStorage.EnableDiagnosticsInSourceGeneratedFiles, CompletionOptionsStorage.ShowItemsFromUnimportedNamespaces, CompletionOptionsStorage.ShowNewSnippetExperienceUserOption, CompletionOptionsStorage.TriggerOnDeletion, diff --git a/src/Features/Core/Portable/ExternalAccess/UnitTesting/SolutionCrawler/UnitTestingWorkCoordinator.cs b/src/Features/Core/Portable/ExternalAccess/UnitTesting/SolutionCrawler/UnitTestingWorkCoordinator.cs index 6b4436bfaa40a..7357141577571 100644 --- a/src/Features/Core/Portable/ExternalAccess/UnitTesting/SolutionCrawler/UnitTestingWorkCoordinator.cs +++ b/src/Features/Core/Portable/ExternalAccess/UnitTesting/SolutionCrawler/UnitTestingWorkCoordinator.cs @@ -25,7 +25,6 @@ internal sealed partial class UnitTestingWorkCoordinator : IUnitTestingWorkCoord { private readonly CountLogAggregator _logAggregator = new(); private readonly IAsynchronousOperationListener _listener; - private readonly Microsoft.CodeAnalysis.SolutionCrawler.ISolutionCrawlerOptionsService? _solutionCrawlerOptionsService; private readonly CancellationTokenSource _shutdownNotificationSource = new(); private readonly CancellationToken _shutdownToken; @@ -43,7 +42,6 @@ public UnitTestingWorkCoordinator( Registration = registration; _listener = listener; - _solutionCrawlerOptionsService = Registration.Services.GetService(); // event and worker queues _shutdownToken = _shutdownNotificationSource.Token; @@ -294,36 +292,34 @@ private void EnqueueDocumentChangedEvent(Solution oldSolution, Solution newSolut // If all features are enabled for source generated documents, the solution crawler needs to // include them in incremental analysis. - if (_solutionCrawlerOptionsService?.EnableDiagnosticsInSourceGeneratedFiles == true) + + // TODO: if this becomes a hot spot, we should be able to expose/access the dictionary + // underneath GetSourceGeneratedDocumentsAsync rather than create a new one here. + var oldProjectSourceGeneratedDocuments = await oldProject.GetSourceGeneratedDocumentsAsync(_shutdownToken).ConfigureAwait(false); + var oldProjectSourceGeneratedDocumentsById = oldProjectSourceGeneratedDocuments.ToDictionary(static document => document.Id); + var newProjectSourceGeneratedDocuments = await newProject.GetSourceGeneratedDocumentsAsync(_shutdownToken).ConfigureAwait(false); + var newProjectSourceGeneratedDocumentsById = newProjectSourceGeneratedDocuments.ToDictionary(static document => document.Id); + + foreach (var (oldDocumentId, _) in oldProjectSourceGeneratedDocumentsById) { - // TODO: if this becomes a hot spot, we should be able to expose/access the dictionary - // underneath GetSourceGeneratedDocumentsAsync rather than create a new one here. - var oldProjectSourceGeneratedDocuments = await oldProject.GetSourceGeneratedDocumentsAsync(_shutdownToken).ConfigureAwait(false); - var oldProjectSourceGeneratedDocumentsById = oldProjectSourceGeneratedDocuments.ToDictionary(static document => document.Id); - var newProjectSourceGeneratedDocuments = await newProject.GetSourceGeneratedDocumentsAsync(_shutdownToken).ConfigureAwait(false); - var newProjectSourceGeneratedDocumentsById = newProjectSourceGeneratedDocuments.ToDictionary(static document => document.Id); - - foreach (var (oldDocumentId, _) in oldProjectSourceGeneratedDocumentsById) + if (!newProjectSourceGeneratedDocumentsById.ContainsKey(oldDocumentId)) { - if (!newProjectSourceGeneratedDocumentsById.ContainsKey(oldDocumentId)) - { - // This source generated document was removed - EnqueueFullDocumentEvent(oldSolution, oldDocumentId, UnitTestingInvocationReasons.DocumentRemoved); - } + // This source generated document was removed + EnqueueFullDocumentEvent(oldSolution, oldDocumentId, UnitTestingInvocationReasons.DocumentRemoved); } + } - foreach (var (newDocumentId, newDocument) in newProjectSourceGeneratedDocumentsById) + foreach (var (newDocumentId, newDocument) in newProjectSourceGeneratedDocumentsById) + { + if (!oldProjectSourceGeneratedDocumentsById.TryGetValue(newDocumentId, out var oldDocument)) { - if (!oldProjectSourceGeneratedDocumentsById.TryGetValue(newDocumentId, out var oldDocument)) - { - // This source generated document was added - EnqueueFullDocumentEvent(newSolution, newDocumentId, UnitTestingInvocationReasons.DocumentAdded); - } - else - { - // This source generated document may have changed - await EnqueueChangedDocumentWorkItemAsync(oldDocument, newDocument).ConfigureAwait(continueOnCapturedContext: false); - } + // This source generated document was added + EnqueueFullDocumentEvent(newSolution, newDocumentId, UnitTestingInvocationReasons.DocumentAdded); + } + else + { + // This source generated document may have changed + await EnqueueChangedDocumentWorkItemAsync(oldDocument, newDocument).ConfigureAwait(continueOnCapturedContext: false); } } }); @@ -382,11 +378,8 @@ private async Task EnqueueFullProjectWorkItemAsync(Project project, UnitTestingI // If all features are enabled for source generated documents, the solution crawler needs to // include them in incremental analysis. - if (_solutionCrawlerOptionsService?.EnableDiagnosticsInSourceGeneratedFiles == true) - { - foreach (var document in await project.GetSourceGeneratedDocumentsAsync(_shutdownToken).ConfigureAwait(false)) - await EnqueueDocumentWorkItemAsync(project, document.Id, document, invocationReasons).ConfigureAwait(false); - } + foreach (var document in await project.GetSourceGeneratedDocumentsAsync(_shutdownToken).ConfigureAwait(false)) + await EnqueueDocumentWorkItemAsync(project, document.Id, document, invocationReasons).ConfigureAwait(false); } private async Task EnqueueWorkItemAsync(IUnitTestingIncrementalAnalyzer analyzer, UnitTestingReanalyzeScope scope) diff --git a/src/Features/Core/Portable/SolutionCrawler/ISolutionCrawlerOptionsService.cs b/src/Features/Core/Portable/SolutionCrawler/ISolutionCrawlerOptionsService.cs deleted file mode 100644 index 8da918e68b9dc..0000000000000 --- a/src/Features/Core/Portable/SolutionCrawler/ISolutionCrawlerOptionsService.cs +++ /dev/null @@ -1,12 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. -// See the LICENSE file in the project root for more information. - -using Microsoft.CodeAnalysis.Host; - -namespace Microsoft.CodeAnalysis.SolutionCrawler; - -internal interface ISolutionCrawlerOptionsService : IWorkspaceService -{ - bool EnableDiagnosticsInSourceGeneratedFiles { get; } -} diff --git a/src/LanguageServer/Protocol/Features/Options/SolutionCrawlerOptionsService.cs b/src/LanguageServer/Protocol/Features/Options/SolutionCrawlerOptionsService.cs deleted file mode 100644 index 9bbd4d0857434..0000000000000 --- a/src/LanguageServer/Protocol/Features/Options/SolutionCrawlerOptionsService.cs +++ /dev/null @@ -1,19 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. -// See the LICENSE file in the project root for more information. - -using System; -using System.Composition; -using Microsoft.CodeAnalysis.Host.Mef; -using Microsoft.CodeAnalysis.Options; - -namespace Microsoft.CodeAnalysis.SolutionCrawler; - -[ExportWorkspaceService(typeof(ISolutionCrawlerOptionsService)), Shared] -[method: ImportingConstructor] -[method: Obsolete(MefConstruction.ImportingConstructorMessage, error: true)] -internal sealed class SolutionCrawlerOptionsService(IGlobalOptionService globalOptions) : ISolutionCrawlerOptionsService -{ - public bool EnableDiagnosticsInSourceGeneratedFiles - => globalOptions.GetOption(SolutionCrawlerOptionsStorage.EnableDiagnosticsInSourceGeneratedFiles); -} diff --git a/src/LanguageServer/Protocol/Features/Options/SolutionCrawlerOptionsStorage.cs b/src/LanguageServer/Protocol/Features/Options/SolutionCrawlerOptionsStorage.cs index ca57a82cbc693..1a66db7fe4da9 100644 --- a/src/LanguageServer/Protocol/Features/Options/SolutionCrawlerOptionsStorage.cs +++ b/src/LanguageServer/Protocol/Features/Options/SolutionCrawlerOptionsStorage.cs @@ -23,9 +23,6 @@ internal static class SolutionCrawlerOptionsStorage public static readonly PerLanguageOption2 CompilerDiagnosticsScopeOption = new( "dotnet_compiler_diagnostics_scope", defaultValue: CompilerDiagnosticsScope.OpenFiles, group: s_backgroundAnalysisOptionGroup, serializer: EditorConfigValueSerializer.CreateSerializerForEnum()); - public static readonly Option2 EnableDiagnosticsInSourceGeneratedFiles = new( - "dotnet_enable_diagnostics_in_source_generated_files", defaultValue: true, group: s_backgroundAnalysisOptionGroup); - /// /// Enables forced scope when low VM is detected to improve performance. /// diff --git a/src/LanguageServer/Protocol/Handler/Diagnostics/DiagnosticSourceProviders/WorkspaceDocumentsAndProjectDiagnosticSourceProvider.cs b/src/LanguageServer/Protocol/Handler/Diagnostics/DiagnosticSourceProviders/WorkspaceDocumentsAndProjectDiagnosticSourceProvider.cs index e18ca39e8f871..4517be16a7084 100644 --- a/src/LanguageServer/Protocol/Handler/Diagnostics/DiagnosticSourceProviders/WorkspaceDocumentsAndProjectDiagnosticSourceProvider.cs +++ b/src/LanguageServer/Protocol/Handler/Diagnostics/DiagnosticSourceProviders/WorkspaceDocumentsAndProjectDiagnosticSourceProvider.cs @@ -55,7 +55,6 @@ public async ValueTask> CreateDiagnosticSource using var _ = ArrayBuilder.GetInstance(out var result); var solution = context.Solution; - var enableDiagnosticsInSourceGeneratedFiles = solution.Services.GetService()?.EnableDiagnosticsInSourceGeneratedFiles == true; var codeAnalysisService = solution.Services.GetRequiredService(); foreach (var project in WorkspaceDiagnosticSourceHelpers.GetProjectsInPriorityOrder(solution, context.SupportedLanguages)) @@ -75,12 +74,8 @@ async Task AddDocumentsAndProjectAsync(Project project, IDiagnosticAnalyzerServi AddDocumentSources(project.Documents); AddDocumentSources(project.AdditionalDocuments); - // If all features are enabled for source generated documents, then compute todo-comments/diagnostics for them. - if (enableDiagnosticsInSourceGeneratedFiles) - { - var sourceGeneratedDocuments = await project.GetSourceGeneratedDocumentsAsync(cancellationToken).ConfigureAwait(false); - AddDocumentSources(sourceGeneratedDocuments); - } + var sourceGeneratedDocuments = await project.GetSourceGeneratedDocumentsAsync(cancellationToken).ConfigureAwait(false); + AddDocumentSources(sourceGeneratedDocuments); // Finally, add the appropriate FSA or CodeAnalysis project source to get project specific diagnostics, not associated with any document. AddProjectSource(); diff --git a/src/LanguageServer/ProtocolUnitTests/Diagnostics/AbstractPullDiagnosticTestsBase.cs b/src/LanguageServer/ProtocolUnitTests/Diagnostics/AbstractPullDiagnosticTestsBase.cs index d13000fa95ea2..8a23bd2f62524 100644 --- a/src/LanguageServer/ProtocolUnitTests/Diagnostics/AbstractPullDiagnosticTestsBase.cs +++ b/src/LanguageServer/ProtocolUnitTests/Diagnostics/AbstractPullDiagnosticTestsBase.cs @@ -330,8 +330,7 @@ private protected static InitializationOptions GetInitializationOptions( bool useVSDiagnostics, WellKnownLspServerKinds serverKind = WellKnownLspServerKinds.AlwaysActiveVSLspServer, string[]? sourceGeneratedMarkups = null, - IEnumerable? additionalAnalyzers = null, - bool enableDiagnosticsInSourceGeneratedFiles = true) + IEnumerable? additionalAnalyzers = null) { // If no explicit compiler diagnostics scope has been provided, match it with the provided analyzer diagnostics scope compilerDiagnosticsScope ??= analyzerDiagnosticsScope switch @@ -354,7 +353,6 @@ private protected static InitializationOptions GetInitializationOptions( globalOptions.SetGlobalOption(SolutionCrawlerOptionsStorage.CompilerDiagnosticsScopeOption, LanguageNames.CSharp, compilerDiagnosticsScope.Value); globalOptions.SetGlobalOption(SolutionCrawlerOptionsStorage.CompilerDiagnosticsScopeOption, LanguageNames.VisualBasic, compilerDiagnosticsScope.Value); globalOptions.SetGlobalOption(SolutionCrawlerOptionsStorage.CompilerDiagnosticsScopeOption, InternalLanguageNames.TypeScript, compilerDiagnosticsScope.Value); - globalOptions.SetGlobalOption(SolutionCrawlerOptionsStorage.EnableDiagnosticsInSourceGeneratedFiles, enableDiagnosticsInSourceGeneratedFiles); }, ServerKind = serverKind, SourceGeneratedMarkups = sourceGeneratedMarkups ?? [], diff --git a/src/LanguageServer/ProtocolUnitTests/Diagnostics/PullDiagnosticTests.cs b/src/LanguageServer/ProtocolUnitTests/Diagnostics/PullDiagnosticTests.cs index e1ac7c2162ff0..45d49af41c1d7 100644 --- a/src/LanguageServer/ProtocolUnitTests/Diagnostics/PullDiagnosticTests.cs +++ b/src/LanguageServer/ProtocolUnitTests/Diagnostics/PullDiagnosticTests.cs @@ -1048,12 +1048,12 @@ public async Task TestWorkspaceDiagnosticsForClosedFilesWithRunCodeAnalysisFSAOn } [Theory, CombinatorialData] - public async Task SourceGeneratorFailures_FSA(bool useVSDiagnostics, bool mutatingLspWorkspace, bool enableDiagnosticsInSourceGeneratedFiles) + public async Task SourceGeneratorFailures_FSA(bool useVSDiagnostics, bool mutatingLspWorkspace) { await using var testLspServer = await CreateTestLspServerAsync(["class C {}"], mutatingLspWorkspace, - GetInitializationOptions(BackgroundAnalysisScope.FullSolution, CompilerDiagnosticsScope.FullSolution, useVSDiagnostics, enableDiagnosticsInSourceGeneratedFiles: enableDiagnosticsInSourceGeneratedFiles)); + GetInitializationOptions(BackgroundAnalysisScope.FullSolution, CompilerDiagnosticsScope.FullSolution, useVSDiagnostics)); - var generator = new Roslyn.Test.Utilities.TestGenerators.TestSourceGenerator() + var generator = new TestSourceGenerator() { ExecuteImpl = context => throw new InvalidOperationException("Source generator failed") }; diff --git a/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageControl.xaml b/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageControl.xaml index f656217d8d886..7ab31bc3c9d7f 100644 --- a/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageControl.xaml +++ b/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageControl.xaml @@ -80,9 +80,6 @@ Content="{x:Static local:AdvancedOptionPageStrings.Option_Balanced_Run_generators_after_saving_or_building}"/> - - @@ -97,14 +94,6 @@ Content="{x:Static local:AdvancedOptionPageStrings.Option_Always_use_default_symbol_servers_for_navigation}" /> - - - - - - @@ -374,14 +363,6 @@ Content="{x:Static local:AdvancedOptionPageStrings.Option_Automatically_open_stack_trace_explorer_on_focus}" /> - - - - - - diff --git a/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageControl.xaml.cs b/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageControl.xaml.cs index 350f05c4f3c99..cf6c7ba55a6cd 100644 --- a/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageControl.xaml.cs +++ b/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageControl.xaml.cs @@ -68,16 +68,11 @@ public AdvancedOptionPageControl(OptionStore optionStore) : base(optionStore) BindToOption(Automatic_Run_generators_after_any_change, WorkspaceConfigurationOptionsStorage.SourceGeneratorExecution, SourceGeneratorExecutionPreference.Automatic); BindToOption(Balanced_Run_generators_after_saving_or_building, WorkspaceConfigurationOptionsStorage.SourceGeneratorExecution, SourceGeneratorExecutionPreference.Balanced); - BindToOption(Analyze_source_generated_files, SolutionCrawlerOptionsStorage.EnableDiagnosticsInSourceGeneratedFiles); - // Go To Definition BindToOption(Enable_navigation_to_sourcelink_and_embedded_sources, MetadataAsSourceOptionsStorage.NavigateToSourceLinkAndEmbeddedSources); BindToOption(Enable_navigation_to_decompiled_sources, MetadataAsSourceOptionsStorage.NavigateToDecompiledSources); BindToOption(Always_use_default_symbol_servers_for_navigation, MetadataAsSourceOptionsStorage.AlwaysUseDefaultSymbolServers); - // Rename - BindToOption(Rename_asynchronously_exerimental, InlineRenameSessionOptionsStorage.CommitRenameAsynchronously); - // Using Directives BindToOption(PlaceSystemNamespaceFirst, GenerationOptions.PlaceSystemNamespaceFirst, LanguageNames.CSharp); BindToOption(SeparateImportGroups, GenerationOptions.SeparateImportDirectiveGroups, LanguageNames.CSharp); @@ -173,9 +168,6 @@ public AdvancedOptionPageControl(OptionStore optionStore) : base(optionStore) // Stack Trace Explorer BindToOption(AutomaticallyOpenStackTraceExplorer, StackTraceExplorerOptionsStorage.OpenOnFocus); - - // Document Outline - BindToOption(EnableDocumentOutline, DocumentOutlineOptionsStorage.EnableDocumentOutline); } // Since this dialog is constructed once for the lifetime of the application and VS Theme can be changed after the application has started, diff --git a/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageStrings.cs b/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageStrings.cs index dbd71053d7fe8..732505e399528 100644 --- a/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageStrings.cs +++ b/src/VisualStudio/CSharp/Impl/Options/AdvancedOptionPageStrings.cs @@ -76,9 +76,6 @@ public static string Option_Enable_navigation_to_sourcelink_and_embedded_sources public static string Option_Always_use_default_symbol_servers_for_navigation => ServicesVSResources.Always_use_default_symbol_servers_for_navigation; - public static string Option_analyze_source_generated_files - => ServicesVSResources.Analyze_source_generated_files; - public static string Option_Inline_Hints => EditorFeaturesResources.Inline_Hints; @@ -370,18 +367,6 @@ public static string Option_Fix_text_pasted_into_string_literals_experimental public static string Option_Go_To_Definition => ServicesVSResources.Go_To_Definition; - public static string Option_Rename - => EditorFeaturesResources.Rename; - - public static string Option_Rename_asynchronously_experimental - => ServicesVSResources.Rename_asynchronously_experimental; - - public static string Document_Outline - => ServicesVSResources.Document_Outline; - - public static string Option_Enable_document_outline_experimental_requires_restart - => ServicesVSResources.Enable_document_outline_experimental_requires_restart; - public static string Option_Source_Generators => ServicesVSResources.Source_Generators; diff --git a/src/VisualStudio/Core/Def/DocumentOutline/DocumentOutlineOptionsStorage.cs b/src/VisualStudio/Core/Def/DocumentOutline/DocumentOutlineOptionsStorage.cs index c4d6d9ef9bf87..ba5e0cc619c92 100644 --- a/src/VisualStudio/Core/Def/DocumentOutline/DocumentOutlineOptionsStorage.cs +++ b/src/VisualStudio/Core/Def/DocumentOutline/DocumentOutlineOptionsStorage.cs @@ -11,7 +11,5 @@ namespace Microsoft.VisualStudio.LanguageServices.DocumentOutline; /// internal sealed class DocumentOutlineOptionsStorage { - public static readonly Option2 EnableDocumentOutline = new("visual_studio_enable_document_outline", defaultValue: true); - public static readonly Option2 DocumentOutlineSortOrder = new("visual_studio_document_outline_sort_order", defaultValue: SortOption.Location); } diff --git a/src/VisualStudio/Core/Def/LanguageService/AbstractLanguageService`2.VsCodeWindowManager.cs b/src/VisualStudio/Core/Def/LanguageService/AbstractLanguageService`2.VsCodeWindowManager.cs index 61926961f7fb5..2be4bd13fe8c1 100644 --- a/src/VisualStudio/Core/Def/LanguageService/AbstractLanguageService`2.VsCodeWindowManager.cs +++ b/src/VisualStudio/Core/Def/LanguageService/AbstractLanguageService`2.VsCodeWindowManager.cs @@ -242,12 +242,6 @@ int IVsDocOutlineProvider.GetOutline(out IntPtr phwnd, out IOleCommandTarget? pC private void GetOutline(out IntPtr phwnd) { - phwnd = default; - - var enabled = _globalOptions.GetOption(DocumentOutlineOptionsStorage.EnableDocumentOutline); - if (!enabled) - return; - var threadingContext = _languageService.Package.ComponentModel.GetService(); threadingContext.ThrowIfNotOnUIThread(); diff --git a/src/VisualStudio/Core/Def/Options/VisualStudioOptionStorage.cs b/src/VisualStudio/Core/Def/Options/VisualStudioOptionStorage.cs index 79e618b1f14e1..bf66d74e0f091 100644 --- a/src/VisualStudio/Core/Def/Options/VisualStudioOptionStorage.cs +++ b/src/VisualStudio/Core/Def/Options/VisualStudioOptionStorage.cs @@ -339,10 +339,9 @@ public bool TryFetch(LocalUserRegistryOptionPersister persister, OptionKey2 opti {"dotnet_collapse_inline_rename_ui", new RoamingProfileStorage("TextEditor.CollapseRenameUI")}, {"dotnet_preview_inline_rename_changes", new RoamingProfileStorage("TextEditor.Specific.PreviewRename")}, {"dotnet_collapse_suggestions_in_inline_rename_ui", new RoamingProfileStorage("TextEditor.CollapseRenameSuggestionsUI")}, - {"dotnet_commit_rename_asynchronously", new RoamingProfileStorage("TextEditor.Specific.CommitRenameAsynchronously")}, + {"dotnet_commit_rename_asynchronously", new LocalUserProfileStorage(@"Roslyn\Internal\OnOff\Features", "DotnetCommitRenameAsynchronously")}, {"dotnet_rename_get_suggestions_automatically", new FeatureFlagStorage(@"Editor.AutoSmartRenameSuggestions")}, // Option is deprecated, don't use the same RoamingProfileStorage key - // {"dotnet_rename_asynchronously", new RoamingProfileStorage("TextEditor.Specific.RenameAsynchronously")}, {"dotnet_rename_file", new RoamingProfileStorage("TextEditor.Specific.RenameFile")}, {"dotnet_rename_in_comments", new RoamingProfileStorage("TextEditor.Specific.RenameInComments")}, {"dotnet_rename_in_strings", new RoamingProfileStorage("TextEditor.Specific.RenameInStrings")}, @@ -398,7 +397,6 @@ public bool TryFetch(LocalUserRegistryOptionPersister persister, OptionKey2 opti {"dotnet_split_comments", new RoamingProfileStorage("TextEditor.%LANGUAGE%.Specific.SplitComments")}, {"csharp_split_string_literal_on_return", new RoamingProfileStorage("TextEditor.CSharp.Specific.SplitStringLiterals")}, {"visual_studio_open_stack_trace_explorer_on_focus", new RoamingProfileStorage("StackTraceExplorer.Options.OpenOnFocus")}, - {"visual_studio_enable_document_outline", new RoamingProfileStorage(@"DocumentOutline.Enable")}, {"visual_studio_document_outline_sort_order", new RoamingProfileStorage(@"DocumentOutline.SortOrder")}, {"visual_studio_enable_symbol_search", new LocalUserProfileStorage(@"Roslyn\Features\SymbolSearch", "Enabled")}, {"dotnet_unsupported_search_nuget_packages", new RoamingProfileStorage("TextEditor.%LANGUAGE%.Specific.SuggestForTypesInNuGetPackages")}, @@ -418,7 +416,6 @@ public bool TryFetch(LocalUserRegistryOptionPersister persister, OptionKey2 opti {"visual_basic_style_unused_value_expression_statement_preference", new RoamingProfileStorage("TextEditor.VisualBasic.Specific.UnusedValueExpressionStatementPreference")}, {"visual_studio_navigate_to_object_browser", new RoamingProfileStorage("TextEditor.%LANGUAGE%.Specific.NavigateToObjectBrowser")}, {"dotnet_validate_compilation_tracker_states", new FeatureFlagStorage(@"Roslyn.ValidateCompilationTrackerStates")}, - {"dotnet_enable_diagnostics_in_source_generated_files", new RoamingProfileStorage("TextEditor.Roslyn.Specific.EnableDiagnosticsInSourceGeneratedFilesExperiment")}, {"dotnet_source_generator_execution", new RoamingProfileStorage("TextEditor.Roslyn.Specific.SourceGeneratorExecution")}, {"dotnet_reload_changed_analyzer_references", new LocalUserProfileStorage(@"Roslyn\Internal\OnOff\Features", "DotnetReloadChangedAnalyzerReferences")}, {"xaml_enable_lsp_intellisense", new FeatureFlagStorage(@"Xaml.EnableLspIntelliSense")}, diff --git a/src/VisualStudio/Core/Def/ServicesVSResources.resx b/src/VisualStudio/Core/Def/ServicesVSResources.resx index 7da15a9e6f316..77cf600397270 100644 --- a/src/VisualStudio/Core/Def/ServicesVSResources.resx +++ b/src/VisualStudio/Core/Def/ServicesVSResources.resx @@ -1696,9 +1696,6 @@ Additional information: {1} Search Document Outline - - Rename asynchronously (experimental) - Fix analyzer warnings and errors @@ -1724,18 +1721,12 @@ Additional information: {1} Prefer read-only struct - - Analyze source generated files - Prefer read-only struct member Sync namespaces changes - - Enable document outline (experimental, requires restart) - Prefer primary constructors diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.cs.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.cs.xlf index 62a46a9974372..26148c33b72ce 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.cs.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.cs.xlf @@ -87,11 +87,6 @@ Pro navigaci vždy používat výchozí servery symbolů - - Analyze source generated files - Analyzovat zdrojové soubory. - - Analyzer Defaults Výchozí hodnoty analyzátoru @@ -367,11 +362,6 @@ Element není platný. - - Enable document outline (experimental, requires restart) - Povolit osnovu dokumentu (experimentální, vyžaduje restartování) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Povolit protokolování souboru pro diagnostiku (protokolování ve složce '%Temp%\Roslyn') @@ -1197,11 +1187,6 @@ Odebrat nepotřebné direktivy using - - Rename asynchronously (experimental) - Asynchronní přejmenování (experimentální) - - Report invalid JSON strings Nahlásit neplatné řetězce JSON diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.de.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.de.xlf index bab6218f62608..708f2079d6642 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.de.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.de.xlf @@ -87,11 +87,6 @@ Immer Standardsymbolserver für die Navigation verwenden - - Analyze source generated files - Analysieren der von der Quelle generierten Dateien - - Analyzer Defaults Standardwerte des Analysetools @@ -367,11 +362,6 @@ Das Element ist ungültig. - - Enable document outline (experimental, requires restart) - Dokumentgliederung aktivieren (experimentell, Neustart erforderlich) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Dateiprotokollierung für Diagnose aktivieren (protokolliert im Ordner "%Temp%\Roslyn") @@ -1197,11 +1187,6 @@ Nicht benötigte Using-Direktiven entfernen - - Rename asynchronously (experimental) - Asynchron umbenennen (experimentell) - - Report invalid JSON strings Ungültige JSON-Zeichenfolgen melden diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.es.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.es.xlf index 9a14f3acea492..012703a87799a 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.es.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.es.xlf @@ -87,11 +87,6 @@ Usar siempre los servidores de símbolos predeterminados para la navegación - - Analyze source generated files - Analizar archivos generados por el origen - - Analyzer Defaults Valores predeterminados del analizador @@ -367,11 +362,6 @@ El elemento no es válido. - - Enable document outline (experimental, requires restart) - Habilitar esquema de documento (experimental, requiere reinicio) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Habilitar registro de archivos para el diagnóstico (registrados en la carpeta "%Temp%\Roslyn") @@ -1197,11 +1187,6 @@ Eliminar instrucciones Using innecesarias - - Rename asynchronously (experimental) - Cambiar el nombre de forma asincrónica (experimental) - - Report invalid JSON strings Notificar las cadenas JSON no válidas diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.fr.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.fr.xlf index 974900d486a24..e6353f67750b1 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.fr.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.fr.xlf @@ -87,11 +87,6 @@ Toujours utiliser les serveurs de symboles par défaut pour la navigation - - Analyze source generated files - Analyser des fichiers générés par la source - - Analyzer Defaults Valeurs par défaut de l’analyseur @@ -367,11 +362,6 @@ L'élément n'est pas valide. - - Enable document outline (experimental, requires restart) - Activer le plan du document (expérimental, nécessite un redémarrage) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Activer la journalisation des fichiers pour les Diagnostics (connexion au dossier « %Temp% \Roslyn ») @@ -1197,11 +1187,6 @@ Supprimer les Usings inutiles - - Rename asynchronously (experimental) - Renommer de façon asynchrone (expérimentale) - - Report invalid JSON strings Signaler les chaînes JSON non valides diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.it.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.it.xlf index 0751d9cebeb34..e44c273d27c1b 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.it.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.it.xlf @@ -87,11 +87,6 @@ Usa sempre i server di simboli predefiniti per lo spostamento - - Analyze source generated files - Analizza i file generati dall’origine - - Analyzer Defaults Impostazioni predefinite dell'analizzatore @@ -367,11 +362,6 @@ L'elemento non è valido. - - Enable document outline (experimental, requires restart) - Abilita struttura documento (sperimentale, richiede il riavvio) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Abilita la registrazione dei file a scopo di diagnostica (nella cartella '%Temp%\Roslyn') @@ -1197,11 +1187,6 @@ Rimuovi istruzioni using non necessarie - - Rename asynchronously (experimental) - Rinomina in modo asincrono (sperimentale) - - Report invalid JSON strings Segnala stringhe JSON non valide diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ja.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ja.xlf index 593f144483109..acd14ff6164c9 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ja.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ja.xlf @@ -87,11 +87,6 @@ ナビゲーションに常に既定のシンボル サーバーを使用する - - Analyze source generated files - ソース生成ファイルの分析 - - Analyzer Defaults アナライザーの既定値 @@ -367,11 +362,6 @@ 要素が有効ではありません。 - - Enable document outline (experimental, requires restart) - ドキュメント アウトラインを有効にする (試験段階、再起動が必要) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) 診断のファイル ログを有効にする (' %Temp%/Roslyn ' フォルダーにログインしています) @@ -1197,11 +1187,6 @@ 不要な using の削除 - - Rename asynchronously (experimental) - 非同期的な名前の変更 (試験段階) - - Report invalid JSON strings 無効な JSON 文字列を報告する diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ko.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ko.xlf index 4acc19784266d..bcfd8bc272dce 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ko.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ko.xlf @@ -87,11 +87,6 @@ 탐색에 항상 기본 기호 서버 사용 - - Analyze source generated files - 소스에서 생성된 파일 분석 - - Analyzer Defaults 분석기 기본값 @@ -367,11 +362,6 @@ 요소가 잘못되었습니다. - - Enable document outline (experimental, requires restart) - 문서 개요 사용(실험적, 다시 시작해야 함) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) 진단용 파일 로깅 사용('%Temp%\Roslyn' 폴더에 로그인) @@ -1197,11 +1187,6 @@ 불필요한 Using 제거 - - Rename asynchronously (experimental) - 비동기적으로 이름 바꾸기(실험적) - - Report invalid JSON strings 잘못된 JSON 문자열 보고 diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.pl.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.pl.xlf index a425bb31b397e..f3a2f256004fd 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.pl.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.pl.xlf @@ -87,11 +87,6 @@ Zawsze używaj domyślnych serwerów symboli na potrzeby nawigowania - - Analyze source generated files - Analizuj pliki wygenerowane przez źródło - - Analyzer Defaults Ustawienia domyślne analizatora @@ -367,11 +362,6 @@ Element jest nieprawidłowy. - - Enable document outline (experimental, requires restart) - Włącz konspekt dokumentu (eksperymentalne, wymaga ponownego uruchomienia) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Włącz rejestrowanie plików w celach diagnostycznych (rejestrowane w folderze „%Temp%\Roslyn”) @@ -1197,11 +1187,6 @@ Usuń niepotrzebne użycia - - Rename asynchronously (experimental) - Zmień nazwę asynchronicznie (eksperymentalne) - - Report invalid JSON strings Zgłoś nieprawidłowe ciągi JSON diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.pt-BR.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.pt-BR.xlf index c39020eb0283b..5a7606bda168c 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.pt-BR.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.pt-BR.xlf @@ -87,11 +87,6 @@ Sempre usar servidores de símbolo padrão para navegação - - Analyze source generated files - Analisar arquivos gerados pela origem - - Analyzer Defaults Padrões do Analisador @@ -367,11 +362,6 @@ O elemento é inválido. - - Enable document outline (experimental, requires restart) - Habilitar resumo do documento (experimental, requer reinicialização) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Habilite o registro de arquivos para diagnósticos (logado na pasta '%Temp%\Roslyn') @@ -1197,11 +1187,6 @@ Remover Usos Desnecessários - - Rename asynchronously (experimental) - Renomear de forma assíncrona (experimental) - - Report invalid JSON strings Notificar cadeias de caracteres JSON inválidas diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ru.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ru.xlf index 028127470ae75..37526edfde0df 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ru.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.ru.xlf @@ -87,11 +87,6 @@ Всегда использовать серверы символов по умолчанию для навигации - - Analyze source generated files - Анализ сгенерированного исходного файла - - Analyzer Defaults Значения по умолчанию для анализатора @@ -367,11 +362,6 @@ Элемент недопустим. - - Enable document outline (experimental, requires restart) - Включить структуру документа (экспериментальная функция, требуется перезапуск) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Включить ведение журнала файлов для диагностики (в папке "%Temp%\Roslyn") @@ -1197,11 +1187,6 @@ Удалить ненужные директивы using - - Rename asynchronously (experimental) - Асинхронное переименование (экспериментальная функция) - - Report invalid JSON strings Сообщить о недопустимых строках JSON diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.tr.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.tr.xlf index e714666534bb4..a853509192e4f 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.tr.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.tr.xlf @@ -87,11 +87,6 @@ Gezinti için her zaman varsayılan sembol sunucularını kullan - - Analyze source generated files - Kaynak tarafından oluşturulan dosyaları analiz et - - Analyzer Defaults Çözümleyici Varsayılanları @@ -367,11 +362,6 @@ Öğe geçerli değil. - - Enable document outline (experimental, requires restart) - Belge ana hattını etkinleştir (deneysel, yeniden başlatma gerektirir) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) Tanılama için dosya günlüğünü etkinleştir (oturum açan '%Temp%\Roslyn' klasörü) @@ -1197,11 +1187,6 @@ Gereksiz Kullanımları Kaldır - - Rename asynchronously (experimental) - Zaman uyumsuz olarak yeniden adlandırın (deneysel) - - Report invalid JSON strings Geçersiz JSON dizelerini bildir diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.zh-Hans.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.zh-Hans.xlf index edf3a98da79ae..21648f2410c88 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.zh-Hans.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.zh-Hans.xlf @@ -87,11 +87,6 @@ 始终使用默认符号服务器进行导航 - - Analyze source generated files - 分析源生成的文件 - - Analyzer Defaults 分析器默认值 @@ -367,11 +362,6 @@ 元素无效。 - - Enable document outline (experimental, requires restart) - 启用文档大纲(实验性,需要重启) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) 为诊断启用文件日志记录(记录在“%Temp%\Roslyn”文件夹中) @@ -1197,11 +1187,6 @@ 删除不必要的 Using - - Rename asynchronously (experimental) - 异步重命名(试验) - - Report invalid JSON strings 报告无效的 JSON 字符串 diff --git a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.zh-Hant.xlf b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.zh-Hant.xlf index a974c700370b7..95fdeb92676af 100644 --- a/src/VisualStudio/Core/Def/xlf/ServicesVSResources.zh-Hant.xlf +++ b/src/VisualStudio/Core/Def/xlf/ServicesVSResources.zh-Hant.xlf @@ -87,11 +87,6 @@ 一律使用預設符號伺服器進行流覽 - - Analyze source generated files - 分析來源產生的檔案 - - Analyzer Defaults 分析器預設值 @@ -367,11 +362,6 @@ 元素無效。 - - Enable document outline (experimental, requires restart) - 啟用文件大綱 (實驗性,需要重新開機) - - Enable file logging for diagnostics (logged in '%Temp%\Roslyn' folder) 啟用診斷的檔案記錄 (在 '%Temp%\Roslyn' 資料夾中記錄) @@ -1197,11 +1187,6 @@ 移除不必要的 Using - - Rename asynchronously (experimental) - 重新命名非同步 (實驗性) - - Report invalid JSON strings 回報告無效 JSON 字串 diff --git a/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageControl.xaml b/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageControl.xaml index 8cffe98344eaa..64fe27c9896f2 100644 --- a/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageControl.xaml +++ b/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageControl.xaml @@ -80,17 +80,6 @@ Content="{x:Static local:AdvancedOptionPageStrings.Option_Balanced_Run_generators_after_saving_or_building}" /> - - - - - - - - @@ -340,14 +329,6 @@ Content="{x:Static local:AdvancedOptionPageStrings.Include_global_imports}"/> - - - - - - diff --git a/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageControl.xaml.vb b/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageControl.xaml.vb index 74fdd6797b2a7..17d9b7b929749 100644 --- a/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageControl.xaml.vb +++ b/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageControl.xaml.vb @@ -73,11 +73,6 @@ Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.Options BindToOption(Automatic_Run_generators_after_any_change, WorkspaceConfigurationOptionsStorage.SourceGeneratorExecution, SourceGeneratorExecutionPreference.Automatic) BindToOption(Balanced_Run_generators_after_saving_or_building, WorkspaceConfigurationOptionsStorage.SourceGeneratorExecution, SourceGeneratorExecutionPreference.Balanced) - BindToOption(Analyze_source_generated_files, SolutionCrawlerOptionsStorage.EnableDiagnosticsInSourceGeneratedFiles) - - ' Rename - BindToOption(Rename_asynchronously_exerimental, InlineRenameSessionOptionsStorage.CommitRenameAsynchronously) - ' Import directives BindToOption(PlaceSystemNamespaceFirst, GenerationOptions.PlaceSystemNamespaceFirst, LanguageNames.VisualBasic) BindToOption(SeparateImportGroups, GenerationOptions.SeparateImportDirectiveGroups, LanguageNames.VisualBasic) @@ -164,9 +159,6 @@ Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.Options BindToOption(ShowInheritanceMargin, InheritanceMarginOptionsStorage.ShowInheritanceMargin, LanguageNames.VisualBasic, Function() True) BindToOption(InheritanceMarginCombinedWithIndicatorMargin, InheritanceMarginOptionsStorage.InheritanceMarginCombinedWithIndicatorMargin) BindToOption(IncludeGlobalImports, InheritanceMarginOptionsStorage.InheritanceMarginIncludeGlobalImports, LanguageNames.VisualBasic) - - ' Document Outline - BindToOption(EnableDocumentOutline, DocumentOutlineOptionsStorage.EnableDocumentOutline) End Sub ' Since this dialog is constructed once for the lifetime of the application and VS Theme can be changed after the application has started, diff --git a/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageStrings.vb b/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageStrings.vb index 20a7a1ef70176..e37dbd75019b6 100644 --- a/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageStrings.vb +++ b/src/VisualStudio/VisualBasic/Impl/Options/AdvancedOptionPageStrings.vb @@ -8,11 +8,8 @@ Imports Microsoft.CodeAnalysis.SolutionCrawler Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.Options Friend Module AdvancedOptionPageStrings - Public ReadOnly Property Option_AutomaticInsertionOfInterfaceAndMustOverrideMembers As String - Get - Return BasicVSResources.Automatic_insertion_of_Interface_and_MustOverride_members - End Get - End Property + Public ReadOnly Property Option_AutomaticInsertionOfInterfaceAndMustOverrideMembers As String = + BasicVSResources.Automatic_insertion_of_Interface_and_MustOverride_members Public ReadOnly Property Option_Analysis As String = ServicesVSResources.Analysis @@ -20,9 +17,6 @@ Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.Options Public ReadOnly Property Option_Run_background_code_analysis_for As String = ServicesVSResources.Run_background_code_analysis_for_colon - Public ReadOnly Property Option_analyze_source_generated_files As String = - ServicesVSResources.Analyze_source_generated_files - Public ReadOnly Property Option_Background_Analysis_Scope_None As String = WorkspacesResources.None @@ -343,18 +337,6 @@ Namespace Microsoft.VisualStudio.LanguageServices.VisualBasic.Options Public ReadOnly Property Option_Go_To_Definition As String = ServicesVSResources.Go_To_Definition - Public ReadOnly Property Option_Rename As String = - EditorFeaturesResources.Rename - - Public ReadOnly Property Option_Rename_asynchronously_experimental As String = - ServicesVSResources.Rename_asynchronously_experimental - - Public ReadOnly Property Document_Outline As String = - ServicesVSResources.Document_Outline - - Public ReadOnly Property Option_Enable_document_outline_experimental_requires_restart As String = - ServicesVSResources.Enable_document_outline_experimental_requires_restart - Public ReadOnly Property Option_Source_Generators As String = ServicesVSResources.Source_Generators