484 references to Empty
AnalyzerRunner (1)
DiagnosticAnalyzerRunner.cs (1)
309return ImmutableDictionary<string, ImmutableArray<DiagnosticAnalyzer>>.Empty
Aspire.Dashboard.Components.Tests (1)
tests\Shared\DashboardModel\ModelTestHelpers.cs (1)
36Properties = properties?.ToImmutableDictionary() ?? ImmutableDictionary<string, ResourcePropertyViewModel>.Empty,
Aspire.Dashboard.Tests (1)
tests\Shared\DashboardModel\ModelTestHelpers.cs (1)
36Properties = properties?.ToImmutableDictionary() ?? ImmutableDictionary<string, ResourcePropertyViewModel>.Empty,
ILLink.RoslynAnalyzer (1)
DataFlow\LValueFlowCaptureProvider.cs (1)
85 return lvalueFlowCaptureIdBuilder != null ? lvalueFlowCaptureIdBuilder.ToImmutable () : ImmutableDictionary<CaptureId, FlowCaptureKind>.Empty;
Microsoft.AspNetCore.Mvc.ApiExplorer (1)
EndpointModelMetadata.cs (1)
18public override IReadOnlyDictionary<object, object> AdditionalValues { get; } = ImmutableDictionary<object, object>.Empty;
Microsoft.AspNetCore.Server.HttpSys (1)
src\Shared\HttpSys\RequestProcessing\NativeRequestContext.cs (1)
749return ImmutableDictionary<int, ReadOnlyMemory<byte>>.Empty;
Microsoft.AspNetCore.Server.IIS (1)
src\Shared\HttpSys\RequestProcessing\NativeRequestContext.cs (1)
749return ImmutableDictionary<int, ReadOnlyMemory<byte>>.Empty;
Microsoft.AspNetCore.Shared.Tests (1)
src\Shared\HttpSys\RequestProcessing\NativeRequestContext.cs (1)
749return ImmutableDictionary<int, ReadOnlyMemory<byte>>.Empty;
Microsoft.Build (5)
BackEnd\BuildManager\GlobalPropertiesLookup.cs (1)
22return ImmutableDictionary<string, string?>.Empty;
CopyOnWriteDictionary.cs (1)
59_backing = ImmutableDictionary<string, V>.Empty;
Graph\GraphBuildRequestData.cs (1)
230return ImmutableDictionary<string, string?>.Empty;
Graph\GraphBuildResult.cs (1)
34ResultsByNode = ImmutableDictionary<ProjectGraphNode, BuildResult>.Empty;
Graph\ProjectInterpretation.cs (1)
426return ImmutableDictionary<string, string>.Empty;
Microsoft.Build.Framework (1)
ProjectStartedEventArgs.cs (1)
255? ImmutableDictionary<string, string>.Empty
Microsoft.Build.Tasks.Core (1)
CopyOnWriteDictionary.cs (1)
59_backing = ImmutableDictionary<string, V>.Empty;
Microsoft.Build.Utilities.Core (1)
CopyOnWriteDictionary.cs (1)
59_backing = ImmutableDictionary<string, V>.Empty;
Microsoft.CodeAnalysis (35)
CommandLine\AnalyzerConfigSet.cs (1)
516return new GlobalAnalyzerConfig(new Section(GlobalSectionName, AnalyzerOptions.Empty), ImmutableArray<Section>.Empty);
CommandLine\CommonCompiler.SuppressionDiagnostic.cs (1)
68public override ImmutableDictionary<string, string?> Properties => ImmutableDictionary<string, string?>.Empty;
Compilation\Compilation.cs (1)
119set = ImmutableDictionary<string, string>.Empty;
Diagnostic\Diagnostic.cs (7)
62/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>. 109/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>. 137/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>. 191/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>. 241/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>. 406/// Gets property bag for the diagnostic. it will return <see cref="ImmutableDictionary{TKey, TValue}.Empty"/> 411=> ImmutableDictionary<string, string?>.Empty;
Diagnostic\Diagnostic_SimpleDiagnostic.cs (1)
52_properties = properties ?? ImmutableDictionary<string, string?>.Empty;
Diagnostic\DiagnosticInfo.cs (1)
33private static ImmutableDictionary<int, DiagnosticDescriptor> s_errorCodeToDescriptorMap = ImmutableDictionary<int, DiagnosticDescriptor>.Empty;
DiagnosticAnalyzer\AnalysisResultBuilder.cs (3)
25ImmutableDictionary<string, OneOrMany<AdditionalText>>.Empty.WithComparers(PathUtilities.Comparer); 531return ImmutableDictionary<TKey, ImmutableDictionary<DiagnosticAnalyzer, ImmutableArray<Diagnostic>>>.Empty; 566return ImmutableDictionary<DiagnosticAnalyzer, ImmutableArray<Diagnostic>>.Empty;
DiagnosticAnalyzer\AnalyzerFileReference.cs (1)
386_lazyExtensionsPerLanguage = ImmutableDictionary<string, ImmutableArray<TExtension>>.Empty;
DiagnosticAnalyzer\AnalyzerManager.AnalyzerExecutionContext.cs (1)
25private static ImmutableDictionary<LocalizableString, Exception?> s_localizableStringToException = ImmutableDictionary<LocalizableString, Exception?>.Empty.WithComparers(Roslyn.Utilities.ReferenceEqualityComparer.Instance);
DiagnosticAnalyzer\CompilerAnalyzerConfigOptionsProvider.cs (1)
15ImmutableDictionary<object, AnalyzerConfigOptions>.Empty,
DiagnosticAnalyzer\CompilerDiagnosticAnalyzer.CompilationAnalyzer.cs (2)
17private static readonly ImmutableDictionary<string, string?> s_syntactic = ImmutableDictionary<string, string?>.Empty.Add(Origin, Syntactic); 18private static readonly ImmutableDictionary<string, string?> s_declaration = ImmutableDictionary<string, string?>.Empty.Add(Origin, Declaration);
Emit\EditAndContinue\DefinitionMap.cs (1)
48= ImmutableDictionary<INamedTypeSymbolInternal, MetadataLambdasAndClosures>.Empty;
Operations\ControlFlowGraphBuilder.cs (1)
169anonymousFunctionsMapOpt?.ToImmutable() ?? ImmutableDictionary<IFlowAnonymousFunctionOperation, (ControlFlowRegion, int)>.Empty);
ReferenceManager\CommonReferenceManager.State.cs (2)
444_lazyMergedAssemblyReferencesMap = mergedAssemblyReferencesMapOpt?.ToImmutableDictionary() ?? ImmutableDictionary<MetadataReference, ImmutableArray<MetadataReference>>.Empty; 576return lazyBuilder?.ToImmutable() ?? ImmutableDictionary<AssemblyIdentity, AssemblyIdentity>.Empty;
RuleSet\RuleSet.cs (1)
63_specificDiagnosticOptions = specificOptions == null ? ImmutableDictionary<string, ReportDiagnostic>.Empty : specificOptions;
SourceGeneration\GeneratorState.cs (9)
26ImmutableDictionary<string, ImmutableArray<IncrementalGeneratorRunStep>>.Empty, 27ImmutableDictionary<string, ImmutableArray<IncrementalGeneratorRunStep>>.Empty, 28ImmutableDictionary<string, object>.Empty, 41ImmutableDictionary<string, ImmutableArray<IncrementalGeneratorRunStep>>.Empty, 42ImmutableDictionary<string, ImmutableArray<IncrementalGeneratorRunStep>>.Empty, 43ImmutableDictionary<string, object>.Empty, 100ImmutableDictionary<string, ImmutableArray<IncrementalGeneratorRunStep>>.Empty, 101ImmutableDictionary<string, ImmutableArray<IncrementalGeneratorRunStep>>.Empty, 102ImmutableDictionary<string, object>.Empty,
SourceGeneration\Nodes\GeneratorRunStateTable.cs (1)
61return ImmutableDictionary<string, ImmutableArray<IncrementalGeneratorRunStep>>.Empty;
Microsoft.CodeAnalysis.CodeStyle (28)
src\Analyzers\Core\Analyzers\AddAccessibilityModifiers\AbstractAddAccessibilityModifiersDiagnosticAnalyzer.cs (1)
15protected static readonly ImmutableDictionary<string, string?> ModifiersAddedProperties = ImmutableDictionary<string, string?>.Empty.Add(
src\Analyzers\Core\Analyzers\AddRequiredParentheses\AbstractAddRequiredParenthesesDiagnosticAnalyzer.cs (1)
36var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\ForEachCast\AbstractForEachCastDiagnosticAnalyzer.cs (1)
27ImmutableDictionary<string, string?>.Empty.Add(ForEachCastHelpers.IsFixable, ForEachCastHelpers.IsFixable);
src\Analyzers\Core\Analyzers\Helpers\DiagnosticHelper.cs (7)
36/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>. 117return CreateWithMessage(descriptor, location, notificationOption, analyzerOptions, additionalLocations, ImmutableDictionary<string, string?>.Empty, message); 119var tagIndices = ImmutableDictionary<string, IEnumerable<int>>.Empty 129ImmutableDictionary<string, string?>.Empty); 190var tagIndices = ImmutableDictionary<string, IEnumerable<int>>.Empty 216properties ??= ImmutableDictionary<string, string?>.Empty; 251/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>.
src\Analyzers\Core\Analyzers\MatchFolderAndNamespace\AbstractMatchFolderAndNamespaceDiagnosticAnalyzer.cs (1)
88properties: ImmutableDictionary<string, string?>.Empty.Add(MatchFolderAndNamespaceConstants.TargetNamespace, targetNamespace),
src\Analyzers\Core\Analyzers\PopulateSwitch\AbstractPopulateSwitchDiagnosticAnalyzer.cs (1)
71var properties = ImmutableDictionary<string, string?>.Empty
src\Analyzers\Core\Analyzers\RemoveUnnecessarySuppressions\AbstractRemoveUnnecessaryAttributeSuppressionsDiagnosticAnalyzer.cs (1)
100var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\SimplifyBooleanExpression\AbstractSimplifyConditionalDiagnosticAnalyzer.cs (1)
27= ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseAutoProperty\AbstractUseAutoPropertyAnalyzer.cs (1)
653var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseCollectionInitializer\AbstractUseCollectionInitializerDiagnosticAnalyzer.cs (1)
185var properties = shouldUseCollectionExpression ? UseCollectionInitializerHelpers.UseCollectionExpressionProperties : ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseCollectionInitializer\UseCollectionInitializerHelpers.cs (1)
20ImmutableDictionary<string, string?>.Empty.Add(UseCollectionExpressionName, UseCollectionExpressionName);
src\Analyzers\Core\Analyzers\UseConditionalExpression\UseConditionalExpressionHelpers.cs (1)
17ImmutableDictionary<string, string?>.Empty.Add(CanSimplifyName, CanSimplifyName);
src\Analyzers\Core\Analyzers\UseExplicitTupleName\UseExplicitTupleNameDiagnosticAnalyzer.cs (1)
61var properties = ImmutableDictionary<string, string?>.Empty.Add(
src\Analyzers\Core\Analyzers\UseIsNullCheck\AbstractUseIsNullForReferenceEqualsDiagnosticAnalyzer.cs (1)
107var properties = ImmutableDictionary<string, string?>.Empty.Add(
src\Analyzers\Core\Analyzers\UseNullPropagation\AbstractUseNullPropagationDiagnosticAnalyzer.cs (2)
53ImmutableDictionary<string, string?>.Empty.Add(UseNullPropagationConstants.WhenPartIsNullable, ""); 185: ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseNullPropagation\AbstractUseNullPropagationDiagnosticAnalyzer_IfStatement.cs (1)
92: ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseSystemHashCode\UseSystemHashCodeDiagnosticAnalyzer.cs (1)
85ImmutableDictionary<string, string?>.Empty));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Diagnostics\StructuredAnalyzerConfigOptions.cs (1)
48public static readonly StructuredAnalyzerConfigOptions Empty = Create(new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\LValueFlowCaptureProvider.cs (1)
80return lvalueFlowCaptureIdBuilder != null ? lvalueFlowCaptureIdBuilder.ToImmutable() : ImmutableDictionary<CaptureId, FlowCaptureKind>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer.cs (2)
110=> CreateSerializerForEnum(map, ImmutableDictionary<string, T>.Empty); 127var alternativeMap = ImmutableDictionary<string, T>.Empty.WithComparers(keyComparer: StringComparer.OrdinalIgnoreCase)
Microsoft.CodeAnalysis.CodeStyle.Fixes (6)
src\Analyzers\Core\CodeFixes\GenerateConstructor\AbstractGenerateConstructorService.State.cs (3)
71ParameterToNewFieldMap = ImmutableDictionary<string, string>.Empty; 72ParameterToNewPropertyMap = ImmutableDictionary<string, string>.Empty; 647ImmutableDictionary<string, string>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Workspace\Mef\MefLanguageServices.cs (1)
27= ImmutableDictionary<Type, (Lazy<ILanguageService, LanguageServiceMetadata>? lazyService, bool usesFactory)>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Workspace\Mef\MefWorkspaceServices.cs (2)
29= ImmutableDictionary<Type, (Lazy<IWorkspaceService, WorkspaceServiceMetadata>? lazyService, bool usesFactory)>.Empty; 36= ImmutableDictionary<string, MefLanguageServices>.Empty;
Microsoft.CodeAnalysis.CSharp (26)
Binder\DecisionDagBuilder.cs (1)
887ImmutableDictionary<BoundDagTemp, IValueSet>.Empty);
Binder\Imports.cs (2)
28ImmutableDictionary<string, AliasAndUsingDirective>.Empty, 70var expandedAliases = ImmutableDictionary<string, AliasAndUsingDirective>.Empty;
Binder\WithExternAliasesBinder.cs (2)
38ImmutableDictionary<string, AliasAndUsingDirective>.Empty, 56ImmutableDictionary<string, AliasAndUsingDirective>.Empty,
Binder\WithUsingNamespacesAndTypesBinder.cs (1)
352return Imports.Create(ImmutableDictionary<string, AliasAndUsingDirective>.Empty, _usings, ImmutableArray<AliasAndExternAliasDirective>.Empty);
BoundTree\UnboundLambda.cs (2)
521_bindingCache = ImmutableDictionary<(NamedTypeSymbol Type, bool IsExpressionLambda), BoundLambda>.Empty.WithComparers(BindingCacheComparer.Instance); 522_returnInferenceCache = ImmutableDictionary<ReturnInferenceCacheKey, BoundLambda>.Empty;
Compilation\SpeculativeSemanticModelWithMemberModel.cs (1)
26private ImmutableDictionary<CSharpSyntaxNode, MemberSemanticModel> _childMemberModels = ImmutableDictionary<CSharpSyntaxNode, MemberSemanticModel>.Empty;
Compilation\SyntaxTreeSemanticModel.cs (1)
35private ImmutableDictionary<CSharpSyntaxNode, MemberSemanticModel> _memberModels = ImmutableDictionary<CSharpSyntaxNode, MemberSemanticModel>.Empty;
CSharpCompilationOptions.cs (1)
468values = ImmutableDictionary<string, ReportDiagnostic>.Empty;
CSharpParseOptions.cs (3)
59ImmutableDictionary<string, string>.Empty) 74_features = features?.ToImmutableDictionary() ?? ImmutableDictionary<string, string>.Empty; 167?? ImmutableDictionary<string, string>.Empty;
Symbols\ReferenceManager.cs (1)
380ImmutableDictionary<AssemblyIdentity, PortableExecutableReference?>.Empty;
Symbols\Source\SourceNamespaceSymbol.AliasesAndUsings.cs (10)
195return ImmutableDictionary<string, AliasAndUsingDirective>.Empty; 356var globalAliasesMap = ImmutableDictionary<string, AliasAndUsingDirective>.Empty; 380UsingAliasesMap = mergedAliases ?? ImmutableDictionary<string, AliasAndUsingDirective>.Empty, 522return GetUsingsAndDiagnostics(declaringSymbol, declarationSyntax, basesBeingResolved).UsingAliasesMap ?? ImmutableDictionary<string, AliasAndUsingDirective>.Empty; 527return (_lazyGlobalUsings ?? GetGlobalUsingsAndDiagnostics(declaringSymbol, (CSharpSyntaxNode)declarationSyntax.GetSyntax(), basesBeingResolved)).UsingAliasesMap ?? ImmutableDictionary<string, AliasAndUsingDirective>.Empty; 599Debug.Assert((calculated.UsingAliasesMap ?? ImmutableDictionary<string, AliasAndUsingDirective>.Empty).SetEquals(result.UsingAliasesMap ?? ImmutableDictionary<string, AliasAndUsingDirective>.Empty)); 624var globalUsingAliasesMap = ImmutableDictionary<string, AliasAndUsingDirective>.Empty; 1122UsingAliasesMap = ImmutableDictionary<string, AliasAndUsingDirective>.Empty, 1139Imports.Create(UsingAliasesMap ?? ImmutableDictionary<string, AliasAndUsingDirective>.Empty,
Symbols\Source\SourceNamespaceSymbol.cs (1)
23ImmutableDictionary<SingleNamespaceDeclaration, AliasesAndUsings>.Empty.WithComparers(ReferenceEqualityComparer.Instance);
Microsoft.CodeAnalysis.CSharp.CodeStyle (19)
src\Analyzers\CSharp\Analyzers\ConvertNamespace\ConvertToBlockScopedNamespaceDiagnosticAnalyzer.cs (1)
63ImmutableDictionary<string, string?>.Empty);
src\Analyzers\CSharp\Analyzers\ConvertNamespace\ConvertToFileScopedNamespaceDiagnosticAnalyzer.cs (1)
66ImmutableDictionary<string, string?>.Empty);
src\Analyzers\CSharp\Analyzers\ConvertProgram\ConvertToProgramMainDiagnosticAnalyzer.cs (1)
62ImmutableDictionary<string, string?>.Empty));
src\Analyzers\CSharp\Analyzers\ConvertProgram\ConvertToTopLevelStatementsDiagnosticAnalyzer.cs (1)
82ImmutableDictionary<string, string?>.Empty));
src\Analyzers\CSharp\Analyzers\ConvertSwitchStatementToExpression\ConvertSwitchStatementToExpressionDiagnosticAnalyzer.cs (1)
75properties: ImmutableDictionary<string, string?>.Empty
src\Analyzers\CSharp\Analyzers\InvokeDelegateWithConditionalAccess\InvokeDelegateWithConditionalAccessAnalyzer.cs (1)
175var properties = ImmutableDictionary<string, string?>.Empty.Add(
src\Analyzers\CSharp\Analyzers\RemoveUnreachableCode\CSharpRemoveUnreachableCodeDiagnosticAnalyzer.cs (1)
22private static readonly ImmutableDictionary<string, string?> s_subsequentSectionProperties = ImmutableDictionary<string, string?>.Empty.Add(IsSubsequentSection, "");
src\Analyzers\CSharp\Analyzers\UseCollectionExpression\AbstractCSharpUseCollectionExpressionDiagnosticAnalyzer.cs (1)
22ImmutableDictionary<string, string?>.Empty.Add(UseCollectionInitializerHelpers.ChangesSemanticsName, "");
src\Analyzers\CSharp\Analyzers\UseCollectionExpression\UseCollectionExpressionHelpers.cs (1)
1210var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\CSharp\Analyzers\UseExpressionBody\UseExpressionBodyDiagnosticAnalyzer.cs (2)
105var properties = ImmutableDictionary<string, string?>.Empty.Add(nameof(UseExpressionBody), ""); 119var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\CSharp\Analyzers\UseExpressionBodyForLambda\UseExpressionBodyForLambdaDiagnosticAnalyzer.cs (2)
79var properties = ImmutableDictionary<string, string?>.Empty; 92var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\CSharpUseIndexOperatorDiagnosticAnalyzer.cs (1)
212ImmutableDictionary<string, string?>.Empty));
src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\CSharpUseRangeOperatorDiagnosticAnalyzer.cs (1)
267ImmutableDictionary<string, string?>.Empty,
src\Analyzers\CSharp\Analyzers\UseIsNullCheck\CSharpUseIsNullCheckForCastAndEqualityOperatorDiagnosticAnalyzer.cs (1)
19ImmutableDictionary<string, string?>.Empty.Add(UseIsNullConstants.Kind, UseIsNullConstants.CastAndEqualityKey);
src\Analyzers\CSharp\Analyzers\UseNameofInNullableAttribute\CSharpUseNameofInNullableAttributeDiagnosticAnalyzer.cs (1)
112ImmutableDictionary<string, string?>.Empty.Add(NameKey, stringValue)));
src\Analyzers\CSharp\Analyzers\UsePatternCombinators\CSharpUsePatternCombinatorsDiagnosticAnalyzer.cs (1)
28private static readonly ImmutableDictionary<string, string?> s_safeProperties = ImmutableDictionary<string, string?>.Empty.Add(SafeKey, "");
src\Analyzers\CSharp\Analyzers\UseUtf8StringLiteral\UseUtf8StringLiteralDiagnosticAnalyzer.cs (1)
144var properties = ImmutableDictionary<string, string?>.Empty.Add(nameof(ArrayCreationOperationLocation), operationLocation.ToString());
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (5)
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\ConvertToRecordHelpers.cs (4)
378var dictionaryBuilder = ImmutableDictionary<ISymbol, ExpressionSyntax>.Empty.ToBuilder(); 424var dictionaryBuilder = ImmutableDictionary<ISymbol, T>.Empty.ToBuilder(); 430return ImmutableDictionary<ISymbol, T>.Empty; 461return ImmutableDictionary<ISymbol, T>.Empty;
src\Analyzers\CSharp\CodeFixes\UsePrimaryConstructor\CSharpUsePrimaryConstructorCodeFixProvider.cs (1)
471var removedMembers = ImmutableDictionary<ISymbol, (MemberDeclarationSyntax memberNode, SyntaxNode nodeToRemove)>.Empty;
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (1)
Completion\CompletionServiceTests.cs (1)
114var options = new TestOptionSet(ImmutableDictionary<OptionKey, object>.Empty.Add(new OptionKey(ThirdPartyOption.Instance, LanguageNames.CSharp), 1));
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (16)
Attributes\AttributeTests_WellKnownAttributes.cs (6)
8807verify(TestOptions.DebugDll.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add("TEST1", ReportDiagnostic.Warn)), 8813verify(TestOptions.DebugDll.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add("TEST1", ReportDiagnostic.Error)), 8819verify(TestOptions.DebugDll.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add("TEST1", ReportDiagnostic.Hidden)), 8825verify(TestOptions.DebugDll.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add("TEST1", ReportDiagnostic.Suppress))); 8828verify(TestOptions.DebugDll.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add("CS0618", ReportDiagnostic.Error)), 8834verify(TestOptions.DebugDll.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add("CS0618", ReportDiagnostic.Suppress)),
Diagnostics\DiagnosticAnalyzerTests.cs (6)
1508var analyzerConfigOptions = new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty.Add("generated_code", "true")); 1516analyzerConfigOptions = new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty.Add("generated_code", "TRUE")); 1522analyzerConfigOptions = new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty.Add("generated_code", "false")); 1528analyzerConfigOptions = new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty.Add("generated_code", "auto")); 3711var diagnostics = diagnosticsMap.TryGetValue(tree1, out var value) ? value : ImmutableDictionary<DiagnosticAnalyzer, ImmutableArray<Diagnostic>>.Empty; 4195.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add(AnalyzerWithDisabledRules.Rule.Id, ReportDiagnostic.Warn))
Diagnostics\GetDiagnosticsTests.cs (4)
558var analyzerConfigOptions = new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty.Add("dotnet_analyzer_diagnostic.severity", "none")); 560ImmutableDictionary<object, AnalyzerConfigOptions>.Empty.Add(compilation.SyntaxTrees.Single(), analyzerConfigOptions), 604var analyzerConfigOptions = new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty.Add(options.Value.key, options.Value.value)); 606ImmutableDictionary<object, AnalyzerConfigOptions>.Empty.Add(compilation.SyntaxTrees.Single(), analyzerConfigOptions),
Microsoft.CodeAnalysis.CSharp.Features (25)
src\Analyzers\CSharp\Analyzers\ConvertNamespace\ConvertToBlockScopedNamespaceDiagnosticAnalyzer.cs (1)
63ImmutableDictionary<string, string?>.Empty);
src\Analyzers\CSharp\Analyzers\ConvertNamespace\ConvertToFileScopedNamespaceDiagnosticAnalyzer.cs (1)
66ImmutableDictionary<string, string?>.Empty);
src\Analyzers\CSharp\Analyzers\ConvertProgram\ConvertToProgramMainDiagnosticAnalyzer.cs (1)
62ImmutableDictionary<string, string?>.Empty));
src\Analyzers\CSharp\Analyzers\ConvertProgram\ConvertToTopLevelStatementsDiagnosticAnalyzer.cs (1)
82ImmutableDictionary<string, string?>.Empty));
src\Analyzers\CSharp\Analyzers\ConvertSwitchStatementToExpression\ConvertSwitchStatementToExpressionDiagnosticAnalyzer.cs (1)
75properties: ImmutableDictionary<string, string?>.Empty
src\Analyzers\CSharp\Analyzers\InvokeDelegateWithConditionalAccess\InvokeDelegateWithConditionalAccessAnalyzer.cs (1)
175var properties = ImmutableDictionary<string, string?>.Empty.Add(
src\Analyzers\CSharp\Analyzers\RemoveUnreachableCode\CSharpRemoveUnreachableCodeDiagnosticAnalyzer.cs (1)
22private static readonly ImmutableDictionary<string, string?> s_subsequentSectionProperties = ImmutableDictionary<string, string?>.Empty.Add(IsSubsequentSection, "");
src\Analyzers\CSharp\Analyzers\UseCollectionExpression\AbstractCSharpUseCollectionExpressionDiagnosticAnalyzer.cs (1)
22ImmutableDictionary<string, string?>.Empty.Add(UseCollectionInitializerHelpers.ChangesSemanticsName, "");
src\Analyzers\CSharp\Analyzers\UseCollectionExpression\UseCollectionExpressionHelpers.cs (1)
1210var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\CSharp\Analyzers\UseExpressionBody\UseExpressionBodyDiagnosticAnalyzer.cs (2)
105var properties = ImmutableDictionary<string, string?>.Empty.Add(nameof(UseExpressionBody), ""); 119var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\CSharp\Analyzers\UseExpressionBodyForLambda\UseExpressionBodyForLambdaDiagnosticAnalyzer.cs (2)
79var properties = ImmutableDictionary<string, string?>.Empty; 92var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\CSharpUseIndexOperatorDiagnosticAnalyzer.cs (1)
212ImmutableDictionary<string, string?>.Empty));
src\Analyzers\CSharp\Analyzers\UseIndexOrRangeOperator\CSharpUseRangeOperatorDiagnosticAnalyzer.cs (1)
267ImmutableDictionary<string, string?>.Empty,
src\Analyzers\CSharp\Analyzers\UseIsNullCheck\CSharpUseIsNullCheckForCastAndEqualityOperatorDiagnosticAnalyzer.cs (1)
19ImmutableDictionary<string, string?>.Empty.Add(UseIsNullConstants.Kind, UseIsNullConstants.CastAndEqualityKey);
src\Analyzers\CSharp\Analyzers\UseNameofInNullableAttribute\CSharpUseNameofInNullableAttributeDiagnosticAnalyzer.cs (1)
112ImmutableDictionary<string, string?>.Empty.Add(NameKey, stringValue)));
src\Analyzers\CSharp\Analyzers\UsePatternCombinators\CSharpUsePatternCombinatorsDiagnosticAnalyzer.cs (1)
28private static readonly ImmutableDictionary<string, string?> s_safeProperties = ImmutableDictionary<string, string?>.Empty.Add(SafeKey, "");
src\Analyzers\CSharp\Analyzers\UseUtf8StringLiteral\UseUtf8StringLiteralDiagnosticAnalyzer.cs (1)
144var properties = ImmutableDictionary<string, string?>.Empty.Add(nameof(ArrayCreationOperationLocation), operationLocation.ToString());
src\Analyzers\CSharp\CodeFixes\ConvertToRecord\ConvertToRecordHelpers.cs (4)
378var dictionaryBuilder = ImmutableDictionary<ISymbol, ExpressionSyntax>.Empty.ToBuilder(); 424var dictionaryBuilder = ImmutableDictionary<ISymbol, T>.Empty.ToBuilder(); 430return ImmutableDictionary<ISymbol, T>.Empty; 461return ImmutableDictionary<ISymbol, T>.Empty;
src\Analyzers\CSharp\CodeFixes\UsePrimaryConstructor\CSharpUsePrimaryConstructorCodeFixProvider.cs (1)
471var removedMembers = ImmutableDictionary<ISymbol, (MemberDeclarationSyntax memberNode, SyntaxNode nodeToRemove)>.Empty;
UsePatternMatching\CSharpIsAndCastCheckWithoutNameDiagnosticAnalyzer.cs (1)
105ImmutableDictionary<string, string?>.Empty));
Microsoft.CodeAnalysis.CSharp.Features.UnitTests (1)
Diagnostics\Suppression\RemoveUnnecessaryPragmaSuppressionsTests.cs (1)
1063ImmutableDictionary<string, ReportDiagnostic>.Empty
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (8)
Semantics\ImportsTests.cs (2)
124ImmutableDictionary<string, AliasAndUsingDirective>.Empty, 129ImmutableDictionary<string, AliasAndUsingDirective>.Empty,
Semantics\InitOnlyMemberTests.cs (2)
3469ImmutableDictionary<string, ReportDiagnostic>.Empty.Add("CS1685", ReportDiagnostic.Suppress))); 3568ImmutableDictionary<string, ReportDiagnostic>.Empty.Add("CS1685", ReportDiagnostic.Suppress)));
SourceGeneration\GeneratorDriverTests.cs (4)
855var options = new CompilerAnalyzerConfigOptionsProvider(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty.Add("a", "abc").Add("b", "def"))); 2628var builder = ImmutableDictionary<string, string>.Empty.ToBuilder(); 2630var optionsProvider = new CompilerAnalyzerConfigOptionsProvider(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, new DictionaryAnalyzerConfigOptions(builder.ToImmutable()));
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (4)
Syntax\SyntaxTreeTests.cs (4)
166Assert.NotSame(ImmutableDictionary<string, ReportDiagnostic>.Empty, tree.DiagnosticOptions); 176diagnosticOptions: ImmutableDictionary<string, ReportDiagnostic>.Empty, 181Assert.Same(ImmutableDictionary<string, ReportDiagnostic>.Empty, tree.DiagnosticOptions); 220var newTree = tree.WithDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty);
Microsoft.CodeAnalysis.CSharp.Test.Utilities (2)
TestOptions.cs (2)
174return options.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add(key, value)); 179return options.WithSpecificDiagnosticOptions(ImmutableDictionary<string, ReportDiagnostic>.Empty.Add(key1, value).Add(key2, value));
Microsoft.CodeAnalysis.CSharp.Workspaces (3)
LanguageServices\FixAllSpanMappingService\CSharpFixAllSpanMappingService.cs (3)
34return ImmutableDictionary<Document, ImmutableArray<TextSpan>>.Empty; 47return ImmutableDictionary<Document, ImmutableArray<TextSpan>>.Empty; 52return ImmutableDictionary<Document, ImmutableArray<TextSpan>>.Empty
Microsoft.CodeAnalysis.EditorFeatures (4)
ExternalAccess\VSTypeScript\VSTypeScriptEditorInlineRenameService.cs (1)
42return Task.FromResult(ImmutableDictionary<string, ImmutableArray<(string filePath, string content)>>.Empty);
InlineRename\AbstractEditorInlineRenameService.cs (1)
37return Task.FromResult(ImmutableDictionary<string, ImmutableArray<(string filePath, string content)>>.Empty);
Tagging\AbstractAsynchronousTaggerProvider.TagSource.cs (1)
93private ImmutableDictionary<ITextBuffer, TagSpanIntervalTree<TTag>> _cachedTagTrees_mayChangeFromAnyThread = ImmutableDictionary<ITextBuffer, TagSpanIntervalTree<TTag>>.Empty;
Tagging\AbstractAsynchronousTaggerProvider.TagSource_ProduceTags.cs (1)
57ref _cachedTagTrees_mayChangeFromAnyThread, ImmutableDictionary<ITextBuffer, TagSpanIntervalTree<TTag>>.Empty);
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (3)
Classification\FormattedClassification.cs (1)
16private static readonly ImmutableDictionary<string, string> s_classificationPrefixToTestHelperMap = ImmutableDictionary<string, string>.Empty
Squiggles\TestDiagnosticTagProducer.cs (1)
43properties: ImmutableDictionary<string, string?>.Empty,
StubSettingsManagerHost.cs (1)
88private ImmutableDictionary<string, VersionedString> _values = ImmutableDictionary<string, VersionedString>.Empty;
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (4)
Diagnostics\DiagnosticDataTests.cs (4)
124properties: ImmutableDictionary<string, string>.Empty, 157properties: ImmutableDictionary<string, string>.Empty, 203properties: ImmutableDictionary<string, string>.Empty, 251properties: ImmutableDictionary<string, string>.Empty,
Microsoft.CodeAnalysis.EditorFeatures.Wpf (1)
InlineRename\UI\SmartRename\SmartRenameViewModel.cs (1)
180var smartRenameContext = ImmutableDictionary<string, ImmutableArray<(string filePath, string content)>>.Empty;
Microsoft.CodeAnalysis.EditorFeatures2.UnitTests (1)
Diagnostics\DiagnosticProviderTests.vb (1)
355properties:=ImmutableDictionary(Of String, String).Empty,
Microsoft.CodeAnalysis.ExternalAccess.FSharp (2)
FSharpDocumentSpan.cs (1)
25public ImmutableDictionary<string, object> Properties { get; } = ImmutableDictionary<string, object>.Empty;
Internal\Editor\FSharpEditorInlineRenameService.cs (1)
208return Task.FromResult(ImmutableDictionary<string, ImmutableArray<(string filePath, string content)>>.Empty);
Microsoft.CodeAnalysis.ExternalAccess.OmniSharp (1)
Formatting\OmniSharpSyntaxFormattingOptionsWrapper.cs (1)
30StructuredAnalyzerConfigOptions.Create(new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty
Microsoft.CodeAnalysis.Features (50)
CodeRefactorings\CodeRefactoringService.cs (1)
42private ImmutableDictionary<CodeRefactoringProvider, FixAllProviderInfo?> _fixAllProviderMap = ImmutableDictionary<CodeRefactoringProvider, FixAllProviderInfo?>.Empty;
Common\AbstractProjectExtensionProvider.cs (1)
30private ImmutableDictionary<string, ImmutableArray<TExtension>> _extensionsPerLanguage = ImmutableDictionary<string, ImmutableArray<TExtension>>.Empty;
Completion\CompletionChange.cs (1)
47: this(textChange, textChanges, newPosition, includesCommitCharacter, ImmutableDictionary<string, string>.Empty)
Completion\Providers\Snippets\AbstractSnippetCompletionProvider.cs (1)
60var props = ImmutableDictionary<string, string>.Empty
ConvertAnonymousType\AbstractConvertAnonymousTypeToClassCodeRefactoringProvider.cs (1)
395semanticModel, parameters, parameterToPropMap, ImmutableDictionary<string, string>.Empty,
ConvertTupleToStruct\AbstractConvertTupleToStructCodeRefactoringProvider.cs (1)
942semanticModel, parameters, parameterToPropMap, ImmutableDictionary<string, string>.Empty,
Diagnostics\DiagnosticAnalyzerTelemetry.cs (2)
48=> _analyzerInfoMap = ImmutableDictionary<Type, Data>.Empty; 64_analyzerInfoMap = ImmutableDictionary<Type, Data>.Empty;
EditAndContinue\ActiveStatementsMap.cs (3)
22new(ImmutableDictionary<string, ImmutableArray<ActiveStatement>>.Empty, 23ImmutableDictionary<ManagedInstructionId, ActiveStatement>.Empty); 56_lazyOldDocumentActiveStatements = ImmutableDictionary<SyntaxTree, ImmutableArray<UnmappedActiveStatement>>.Empty;
EditAndContinue\DebuggingSession.cs (1)
127nonRemappableRegions: ImmutableDictionary<ManagedMethodId, ImmutableArray<NonRemappableRegion>>.Empty,
EditAndContinue\DeclarationBodyMap.cs (2)
17ImmutableDictionary<SyntaxNode, SyntaxNode>.Empty); 37=> new(match.Matches, match.ReverseMatches, ImmutableDictionary<SyntaxNode, SyntaxNode>.Empty);
EmbeddedLanguages\Json\LanguageServices\AbstractJsonDetectionAnalyzer.cs (2)
26ImmutableDictionary<string, string?>.Empty.Add(StrictKey, ""); 90: ImmutableDictionary<string, string?>.Empty;
EmbeddedLanguages\RegularExpressions\RegexParser.cs (2)
145ImmutableDictionary<string, TextSpan>.Empty, 146ImmutableDictionary<int, TextSpan>.Empty).ParseTree();
FindUsages\DefinitionItem.cs (2)
133Properties = properties ?? ImmutableDictionary<string, string>.Empty; 262properties ??= ImmutableDictionary<string, string>.Empty;
FindUsages\DefinitionItemFactory.cs (1)
256var properties = ImmutableDictionary<string, string>.Empty;
InheritanceMargin\AbstractInheritanceMarginService_Helpers.cs (1)
733properties: ImmutableDictionary<string, string>.Empty.WithMetadataSymbolProperties(symbol, originatingProjectId));
PreferFrameworkType\PreferFrameworkTypeConstants.cs (1)
15ImmutableDictionary<string, string>.Empty.Add(PreferFrameworkType, "");
src\Analyzers\Core\Analyzers\AddAccessibilityModifiers\AbstractAddAccessibilityModifiersDiagnosticAnalyzer.cs (1)
15protected static readonly ImmutableDictionary<string, string?> ModifiersAddedProperties = ImmutableDictionary<string, string?>.Empty.Add(
src\Analyzers\Core\Analyzers\AddRequiredParentheses\AbstractAddRequiredParenthesesDiagnosticAnalyzer.cs (1)
36var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\ForEachCast\AbstractForEachCastDiagnosticAnalyzer.cs (1)
27ImmutableDictionary<string, string?>.Empty.Add(ForEachCastHelpers.IsFixable, ForEachCastHelpers.IsFixable);
src\Analyzers\Core\Analyzers\Helpers\DiagnosticHelper.cs (7)
36/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>. 117return CreateWithMessage(descriptor, location, notificationOption, analyzerOptions, additionalLocations, ImmutableDictionary<string, string?>.Empty, message); 119var tagIndices = ImmutableDictionary<string, IEnumerable<int>>.Empty 129ImmutableDictionary<string, string?>.Empty); 190var tagIndices = ImmutableDictionary<string, IEnumerable<int>>.Empty 216properties ??= ImmutableDictionary<string, string?>.Empty; 251/// <see cref="ImmutableDictionary{TKey, TValue}.Empty"/>.
src\Analyzers\Core\Analyzers\MatchFolderAndNamespace\AbstractMatchFolderAndNamespaceDiagnosticAnalyzer.cs (1)
88properties: ImmutableDictionary<string, string?>.Empty.Add(MatchFolderAndNamespaceConstants.TargetNamespace, targetNamespace),
src\Analyzers\Core\Analyzers\PopulateSwitch\AbstractPopulateSwitchDiagnosticAnalyzer.cs (1)
71var properties = ImmutableDictionary<string, string?>.Empty
src\Analyzers\Core\Analyzers\RemoveUnnecessarySuppressions\AbstractRemoveUnnecessaryAttributeSuppressionsDiagnosticAnalyzer.cs (1)
100var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\SimplifyBooleanExpression\AbstractSimplifyConditionalDiagnosticAnalyzer.cs (1)
27= ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseAutoProperty\AbstractUseAutoPropertyAnalyzer.cs (1)
653var properties = ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseCollectionInitializer\AbstractUseCollectionInitializerDiagnosticAnalyzer.cs (1)
185var properties = shouldUseCollectionExpression ? UseCollectionInitializerHelpers.UseCollectionExpressionProperties : ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseCollectionInitializer\UseCollectionInitializerHelpers.cs (1)
20ImmutableDictionary<string, string?>.Empty.Add(UseCollectionExpressionName, UseCollectionExpressionName);
src\Analyzers\Core\Analyzers\UseConditionalExpression\UseConditionalExpressionHelpers.cs (1)
17ImmutableDictionary<string, string?>.Empty.Add(CanSimplifyName, CanSimplifyName);
src\Analyzers\Core\Analyzers\UseExplicitTupleName\UseExplicitTupleNameDiagnosticAnalyzer.cs (1)
61var properties = ImmutableDictionary<string, string?>.Empty.Add(
src\Analyzers\Core\Analyzers\UseIsNullCheck\AbstractUseIsNullForReferenceEqualsDiagnosticAnalyzer.cs (1)
107var properties = ImmutableDictionary<string, string?>.Empty.Add(
src\Analyzers\Core\Analyzers\UseNullPropagation\AbstractUseNullPropagationDiagnosticAnalyzer.cs (2)
53ImmutableDictionary<string, string?>.Empty.Add(UseNullPropagationConstants.WhenPartIsNullable, ""); 185: ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseNullPropagation\AbstractUseNullPropagationDiagnosticAnalyzer_IfStatement.cs (1)
92: ImmutableDictionary<string, string?>.Empty;
src\Analyzers\Core\Analyzers\UseSystemHashCode\UseSystemHashCodeDiagnosticAnalyzer.cs (1)
85ImmutableDictionary<string, string?>.Empty));
src\Analyzers\Core\CodeFixes\GenerateConstructor\AbstractGenerateConstructorService.State.cs (3)
71ParameterToNewFieldMap = ImmutableDictionary<string, string>.Empty; 72ParameterToNewPropertyMap = ImmutableDictionary<string, string>.Empty; 647ImmutableDictionary<string, string>.Empty;
Microsoft.CodeAnalysis.Features.UnitTests (10)
EditAndContinue\ActiveStatementsMapTests.cs (4)
141var map = ActiveStatementsMap.Create(debugInfos, remapping: ImmutableDictionary<ManagedMethodId, ImmutableArray<NonRemappableRegion>>.Empty); 191var map = ActiveStatementsMap.Create(debugInfos, remapping: ImmutableDictionary<ManagedMethodId, ImmutableArray<NonRemappableRegion>>.Empty); 302var remapping = ImmutableDictionary<ManagedMethodId, ImmutableArray<NonRemappableRegion>>.Empty.Add( 340var remapping = ImmutableDictionary<ManagedMethodId, ImmutableArray<NonRemappableRegion>>.Empty.Add(
EditAndContinue\EditSessionActiveStatementsTests.cs (3)
60debuggingSession.RestartEditSession(nonRemappableRegions ?? ImmutableDictionary<ManagedMethodId, ImmutableArray<NonRemappableRegion>>.Empty, inBreakState: true); 266previousNonRemappableRegions: ImmutableDictionary<ManagedMethodId, ImmutableArray<NonRemappableRegion>>.Empty, 381previousNonRemappableRegions: ImmutableDictionary<ManagedMethodId, ImmutableArray<NonRemappableRegion>>.Empty,
EditAndContinue\EmitSolutionUpdateResultsTests.cs (3)
88properties: ImmutableDictionary<string, string?>.Empty, 104properties: ImmutableDictionary<string, string?>.Empty, 121properties: ImmutableDictionary<string, string?>.Empty,
Microsoft.CodeAnalysis.LanguageServer (6)
BrokeredServices\BrokeredServiceBridgeProvider.cs (1)
55var serviceBroker = container.GetLimitedAccessServiceBroker(ServiceAudience.Local, ImmutableDictionary<string, string>.Empty, ClientCredentialsPolicy.RequestOverridesDefault);
BrokeredServices\BrokeredServiceContainer.cs (3)
18: base(ImmutableDictionary<ServiceMoniker, ServiceRegistration>.Empty, isClientOfExclusiveServer: false, joinableTaskFactory: null, traceSource) 23=> ImmutableDictionary<string, string>.Empty; 71return new(ImmutableDictionary<string, string>.Empty);
HostWorkspace\LanguageServerProjectSystem.cs (2)
86? ImmutableDictionary<string, string>.Empty 87: ImmutableDictionary<string, string>.Empty.Add("RazorDesignTimeTargets", razorDesignTimePath);
Microsoft.CodeAnalysis.LanguageServer.Protocol (23)
Features\CodeFixes\CodeFixService.cs (5)
55private ImmutableDictionary<CodeFixProvider, ImmutableArray<DiagnosticId>> _fixerToFixableIdsMap = ImmutableDictionary<CodeFixProvider, ImmutableArray<DiagnosticId>>.Empty; 56private ImmutableDictionary<object, FixAllProviderInfo?> _fixAllProviderMap = ImmutableDictionary<object, FixAllProviderInfo?>.Empty; 57private ImmutableDictionary<CodeFixProvider, CodeChangeProviderMetadata?> _fixerToMetadataMap = ImmutableDictionary<CodeFixProvider, CodeChangeProviderMetadata?>.Empty; 366fixerMap = ImmutableDictionary<DiagnosticId, ImmutableArray<CodeFixProvider>>.Empty; 961? ImmutableDictionary<DiagnosticId, ImmutableArray<CodeFixProvider>>.Empty
Features\Diagnostics\DocumentAnalysisExecutor_Helpers.cs (1)
124properties: ImmutableDictionary<string, string?>.Empty,
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.AnalysisData.cs (1)
141return new ProjectAnalysisData(project.Id, VersionStamp.Default, ImmutableDictionary<DiagnosticAnalyzer, DiagnosticAnalysisResult>.Empty);
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.Executor.cs (4)
96var result = ImmutableDictionary<DiagnosticAnalyzer, DiagnosticAnalysisResult>.Empty; 323syntaxLocalMap: lazyLoadDiagnostics?.ToImmutable() ?? ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 324semanticLocalMap: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 325nonLocalMap: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty,
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.InProcOrRemoteHostAnalyzerRunner.cs (2)
140var builderMap = ImmutableDictionary<DiagnosticAnalyzer, DiagnosticAnalysisResultBuilder>.Empty; 160var telemetry = ImmutableDictionary<DiagnosticAnalyzer, AnalyzerTelemetryInfo>.Empty;
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.ProjectState.cs (3)
497_syntaxLocals?.ToImmutable() ?? ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 498_semanticLocals?.ToImmutable() ?? ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 499_nonLocals?.ToImmutable() ?? ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty,
Features\Diagnostics\EngineV2\DiagnosticIncrementalAnalyzer.StateManager.cs (2)
54_hostAnalyzerStateMap = ImmutableDictionary<HostAnalyzerStateSetKey, HostAnalyzerStateSets>.Empty; 55_projectAnalyzerStateMap = ImmutableDictionary<ProjectId, ProjectAnalyzerStateSets>.Empty;
Handler\Configuration\DidChangeConfigurationNotificationHandler.cs (1)
42private static readonly ImmutableDictionary<string, string> s_languageNameToPrefix = ImmutableDictionary<string, string>.Empty
Handler\Diagnostics\DiagnosticSources\TaskListDiagnosticSource.cs (3)
23private static readonly ImmutableDictionary<string, string?> s_lowPriorityProperties = ImmutableDictionary<string, string?>.Empty.Add(Priority, Low); 24private static readonly ImmutableDictionary<string, string?> s_mediumPriorityProperties = ImmutableDictionary<string, string?>.Empty.Add(Priority, Medium); 25private static readonly ImmutableDictionary<string, string?> s_highPriorityProperties = ImmutableDictionary<string, string?>.Empty.Add(Priority, High);
Workspaces\LspWorkspaceManager.cs (1)
115private ImmutableDictionary<Uri, (SourceText Text, string LanguageId)> _trackedDocuments = ImmutableDictionary<Uri, (SourceText, string)>.Empty.WithComparers(LspUriComparer.Instance);
Microsoft.CodeAnalysis.LanguageServer.Protocol.UnitTests (5)
Diagnostics\AdditionalFileDiagnosticsTests.cs (1)
118=> new(ImmutableDictionary<string, ImmutableArray<DiagnosticAnalyzer>>.Empty.Add(LanguageNames.CSharp, ImmutableArray.Create(
Diagnostics\DiagnosticsPullCacheTests.cs (1)
124isEnabledByDefault: true, warningLevel: 0, [], ImmutableDictionary<string, string?>.Empty,context.Document!.Project.Id,
Diagnostics\NonLocalDiagnosticTests.cs (1)
71=> new(ImmutableDictionary<string, ImmutableArray<DiagnosticAnalyzer>>.Empty.Add(LanguageNames.CSharp, ImmutableArray.Create(
Diagnostics\PullDiagnosticTests.cs (1)
1289properties: ImmutableDictionary<string, string?>.Empty,
Diagnostics\WorkspaceProjectDiagnosticsTests.cs (1)
67=> new(ImmutableDictionary<string, ImmutableArray<DiagnosticAnalyzer>>.Empty.Add(LanguageNames.CSharp, ImmutableArray.Create(
Microsoft.CodeAnalysis.Remote.ServiceHub (7)
Services\ClientOptionsProvider.cs (1)
17private ImmutableDictionary<string, AsyncLazy<TOptions>> _cache = ImmutableDictionary<string, AsyncLazy<TOptions>>.Empty;
Services\DiagnosticAnalyzer\DiagnosticComputer.cs (1)
405var builderMap = ImmutableDictionary<DiagnosticAnalyzer, DiagnosticAnalysisResultBuilder>.Empty;
src\VisualStudio\Core\Def\Telemetry\Shared\AbstractAggregatingLog.cs (2)
31private ImmutableDictionary<string, (TAggregator aggregator, TelemetryEvent TelemetryEvent, object Lock)> _aggregations = ImmutableDictionary<string, (TAggregator, TelemetryEvent, object)>.Empty; 125_aggregations = ImmutableDictionary<string, (TAggregator, TelemetryEvent, object)>.Empty;
src\VisualStudio\Core\Def\Telemetry\Shared\TelemetryLogProvider.cs (3)
23private ImmutableDictionary<FunctionId, VisualStudioTelemetryLog> _logs = ImmutableDictionary<FunctionId, VisualStudioTelemetryLog>.Empty; 28private ImmutableDictionary<FunctionId, AggregatingHistogramLog> _histogramLogs = ImmutableDictionary<FunctionId, AggregatingHistogramLog>.Empty; 33private ImmutableDictionary<FunctionId, AggregatingCounterLog> _counterLogs = ImmutableDictionary<FunctionId, AggregatingCounterLog>.Empty;
Microsoft.CodeAnalysis.Remote.Workspaces (1)
VisualStudioMefHostServices.cs (1)
24= ImmutableDictionary<ExportKey, IEnumerable>.Empty;
Microsoft.CodeAnalysis.Scripting (1)
Hosting\Resolvers\RuntimeMetadataReferenceResolver.cs (1)
208return ImmutableDictionary<string, string>.Empty;
Microsoft.CodeAnalysis.Scripting.UnitTests (2)
RuntimeMetadataReferenceResolverTests.cs (2)
32packageResolver: new PackageResolver(ImmutableDictionary<string, ImmutableArray<string>>.Empty.Add("nuget:N/1.0", ImmutableArray.Create(assembly1.Path, assembly2.Path))), 34trustedPlatformAssemblies: ImmutableDictionary<string, string>.Empty);
Microsoft.CodeAnalysis.VisualBasic (6)
Scanner\Scanner.vb (1)
152Return ImmutableDictionary(Of String, CConst).Empty
Symbols\ReferenceManager.vb (1)
328ImmutableDictionary(Of AssemblyIdentity, PortableExecutableReference).Empty)
VisualBasicCompilationOptions.vb (1)
856value = ImmutableDictionary(Of String, ReportDiagnostic).Empty
VisualBasicParseOptions.vb (3)
45ImmutableDictionary(Of String, String).Empty) 60_features = If(features, ImmutableDictionary(Of String, String).Empty) 233Return New VisualBasicParseOptions(Me) With {._features = ImmutableDictionary(Of String, String).Empty}
Microsoft.CodeAnalysis.VisualBasic.ExpressionCompiler (4)
CompilationContext.vb (2)
115_displayClassVariables = ImmutableDictionary(Of String, DisplayClassVariable).Empty 1125displayClassVariables = ImmutableDictionary(Of String, DisplayClassVariable).Empty
VisualBasicExpressionCompiler.vb (1)
160Dim assemblyContexts = If(previous.Matches(metadataBlocks), previous.AssemblyContexts, ImmutableDictionary(Of MetadataContextId, VisualBasicMetadataContext).Empty)
VisualBasicInstructionDecoder.vb (1)
99Dim assemblyContexts = If(previous.Matches(metadataBlocks), previous.AssemblyContexts, ImmutableDictionary(Of MetadataContextId, VisualBasicMetadataContext).Empty)
Microsoft.CodeAnalysis.VisualBasic.Syntax.UnitTests (4)
Syntax\SyntaxTreeTests.vb (4)
49Assert.NotSame(ImmutableDictionary(Of String, ReportDiagnostic).Empty, tree.DiagnosticOptions) 56diagnosticOptions:=ImmutableDictionary(Of String, ReportDiagnostic).Empty) 59Assert.Same(ImmutableDictionary(Of String, ReportDiagnostic).Empty, tree.DiagnosticOptions) 90Dim newTree = tree.WithDiagnosticOptions(ImmutableDictionary(Of String, ReportDiagnostic).Empty)
Microsoft.CodeAnalysis.VisualBasic.Workspaces (1)
LanguageServices\FixAllSpanMappingService\VisualBasicFixAllSpanMappingService.vb (1)
24Return Task.FromResult(ImmutableDictionary(Of Document, ImmutableArray(Of TextSpan)).Empty)
Microsoft.CodeAnalysis.Workspaces (54)
CodeFixes\FixAllOccurrences\FixAllContext.DiagnosticProvider.cs (1)
109return ImmutableDictionary<Project, ImmutableArray<Diagnostic>>.Empty;
CodeFixes\FixAllOccurrences\FixAllContextHelper.cs (2)
40return ImmutableDictionary<Document, ImmutableArray<Diagnostic>>.Empty.SetItem(document, documentDiagnostics); 102return ImmutableDictionary<Document, ImmutableArray<Diagnostic>>.Empty;
CodeFixes\FixAllOccurrences\FixAllState.FixMultipleDiagnosticProvider.cs (2)
27ProjectDiagnosticsMap = ImmutableDictionary<Project, ImmutableArray<Diagnostic>>.Empty; 33DocumentDiagnosticsMap = ImmutableDictionary<Document, ImmutableArray<Diagnostic>>.Empty;
CodeRefactorings\FixAllOccurences\FixAllState.cs (2)
99return ImmutableDictionary<Document, Optional<ImmutableArray<TextSpan>>>.Empty; 120return ImmutableDictionary<Document, Optional<ImmutableArray<TextSpan>>>.Empty;
Diagnostics\DiagnosticAnalysisResult.cs (7)
101syntaxLocals: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 102semanticLocals: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 103nonLocals: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 148syntaxLocals: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 150nonLocals: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 285semanticLocals: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty, 286nonLocals: ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty,
Diagnostics\DiagnosticAnalysisResultBuilder.cs (1)
198? ImmutableDictionary<DocumentId, ImmutableArray<DiagnosticData>>.Empty
Diagnostics\DiagnosticAnalysisResultMap.cs (2)
29ImmutableDictionary<TKey, TValue>.Empty, 30ImmutableDictionary<TKey, AnalyzerTelemetryInfo>.Empty);
Diagnostics\DiagnosticData.cs (1)
97= ImmutableDictionary<string, string>.Empty.Add(WellKnownDiagnosticPropertyNames.Origin, WellKnownDiagnosticTags.Build);
Diagnostics\HostDiagnosticAnalyzers.cs (2)
64_compilerDiagnosticAnalyzerMap = ImmutableDictionary<string, DiagnosticAnalyzer>.Empty; 310box.Value ??= ImmutableDictionary<string, SkippedHostAnalyzersInfo>.Empty;
Options\DocumentOptionSet.cs (1)
30: this(configOptions, underlyingOptions, language, ImmutableDictionary<OptionKey, object?>.Empty)
Options\SolutionOptionSet.cs (1)
42: this(globalOptions, values: ImmutableDictionary<OptionKey, object?>.Empty, changedOptionKeys: [])
Rename\ConflictResolution.cs (3)
65_documentToModifiedSpansMap = ImmutableDictionary<DocumentId, ImmutableArray<(TextSpan oldSpan, TextSpan newSpan)>>.Empty; 66_documentToComplexifiedSpansMap = ImmutableDictionary<DocumentId, ImmutableArray<ComplexifiedSpan>>.Empty; 67_documentToRelatedLocationsMap = ImmutableDictionary<DocumentId, ImmutableArray<RelatedLocation>>.Empty;
SemanticModelReuse\SemanticModelWorkspaceServiceFactory.SemanticModelWorkspaceService.cs (2)
59private ImmutableDictionary<DocumentId, SemanticModelReuseInfo?> _semanticModelMap = ImmutableDictionary<DocumentId, SemanticModelReuseInfo?>.Empty; 77_semanticModelMap = ImmutableDictionary<DocumentId, SemanticModelReuseInfo?>.Empty;
Serialization\SerializerService.cs (1)
202return ImmutableDictionary<string, StructuredAnalyzerConfigOptions>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Diagnostics\StructuredAnalyzerConfigOptions.cs (1)
48public static readonly StructuredAnalyzerConfigOptions Empty = Create(new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\LValueFlowCaptureProvider.cs (1)
80return lvalueFlowCaptureIdBuilder != null ? lvalueFlowCaptureIdBuilder.ToImmutable() : ImmutableDictionary<CaptureId, FlowCaptureKind>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer.cs (2)
110=> CreateSerializerForEnum(map, ImmutableDictionary<string, T>.Empty); 127var alternativeMap = ImmutableDictionary<string, T>.Empty.WithComparers(keyComparer: StringComparer.OrdinalIgnoreCase)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Workspace\Mef\MefLanguageServices.cs (1)
27= ImmutableDictionary<Type, (Lazy<ILanguageService, LanguageServiceMetadata>? lazyService, bool usesFactory)>.Empty;
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Workspace\Mef\MefWorkspaceServices.cs (2)
29= ImmutableDictionary<Type, (Lazy<IWorkspaceService, WorkspaceServiceMetadata>? lazyService, bool usesFactory)>.Empty; 36= ImmutableDictionary<string, MefLanguageServices>.Empty;
Workspace\Host\Metadata\MetadataReferenceCache.cs (1)
21= ImmutableDictionary<string, ReferenceSet>.Empty;
Workspace\ProjectSystem\ProjectSystemProjectFactory.cs (2)
61private ImmutableDictionary<ProjectId, string?> _projectToMaxSupportedLangVersionMap = ImmutableDictionary<ProjectId, string?>.Empty; 64private ImmutableDictionary<ProjectId, string> _projectToDependencyNodeTargetIdentifier = ImmutableDictionary<ProjectId, string>.Empty;
Workspace\ProjectSystem\ProjectSystemProjectFactory.ProjectUpdateState.cs (2)
61ImmutableDictionary<string, ImmutableArray<ProjectId>>.Empty.WithComparers(StringComparer.OrdinalIgnoreCase), 62ImmutableDictionary<ProjectId, ProjectReferenceInformation>.Empty, [], [], [], []);
Workspace\Solution\Project.cs (4)
29private ImmutableDictionary<DocumentId, Document?> _idToDocumentMap = ImmutableDictionary<DocumentId, Document?>.Empty; 30private ImmutableDictionary<DocumentId, SourceGeneratedDocument> _idToSourceGeneratedDocumentMap = ImmutableDictionary<DocumentId, SourceGeneratedDocument>.Empty; 31private ImmutableDictionary<DocumentId, AdditionalDocument?> _idToAdditionalDocumentMap = ImmutableDictionary<DocumentId, AdditionalDocument?>.Empty; 32private ImmutableDictionary<DocumentId, AnalyzerConfigDocument?> _idToAnalyzerConfigDocumentMap = ImmutableDictionary<DocumentId, AnalyzerConfigDocument?>.Empty;
Workspace\Solution\ProjectDependencyGraph.cs (2)
79transitiveReferencesMap: ImmutableDictionary<ProjectId, ImmutableHashSet<ProjectId>>.Empty, 80reverseTransitiveReferencesMap: ImmutableDictionary<ProjectId, ImmutableHashSet<ProjectId>>.Empty,
Workspace\Solution\Solution.cs (1)
49_projectIdToProjectMap = ImmutableDictionary<ProjectId, Project>.Empty;
Workspace\Solution\SolutionInfo.cs (1)
87=> Create(id, version, filePath, projects, analyzerReferences, ImmutableDictionary<string, StructuredAnalyzerConfigOptions>.Empty);
Workspace\Solution\SolutionState.cs (5)
48public ImmutableDictionary<string, StructuredAnalyzerConfigOptions> FallbackAnalyzerOptions { get; } = ImmutableDictionary<string, StructuredAnalyzerConfigOptions>.Empty; 54internal ImmutableDictionary<string, int> ProjectCountByLanguage { get; } = ImmutableDictionary<string, int>.Empty; 61private ImmutableDictionary<string, ImmutableArray<DocumentId>> _lazyFilePathToRelatedDocumentIds = ImmutableDictionary<string, ImmutableArray<DocumentId>>.Empty.WithComparers(FilePathComparer); 118projectCountByLanguage: ImmutableDictionary<string, int>.Empty, 119idToProjectStateMap: ImmutableDictionary<ProjectId, ProjectState>.Empty,
Workspace\Workspace.cs (1)
86_latestSolution = CreateSolution(info, emptyOptions, analyzerReferences: [], fallbackAnalyzerOptions: ImmutableDictionary<string, StructuredAnalyzerConfigOptions>.Empty);
Microsoft.CodeAnalysis.Workspaces.Desktop (1)
Workspace\Host\Mef\MefV1HostServices.cs (1)
36= ImmutableDictionary<ExportKey, IEnumerable>.Empty;
Microsoft.CodeAnalysis.Workspaces.MSBuild (3)
MSBuild\BuildHostProcessManager.cs (1)
34_globalMSBuildProperties = globalMSBuildProperties ?? ImmutableDictionary<string, string>.Empty;
MSBuild\MSBuildWorkspace.cs (2)
53return Create(ImmutableDictionary<string, string>.Empty); 72return Create(ImmutableDictionary<string, string>.Empty, hostServices);
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (2)
Build\ProjectBuildManager.cs (2)
74_additionalGlobalProperties = additionalGlobalProperties ?? ImmutableDictionary<string, string>.Empty; 174globalProperties ??= ImmutableDictionary<string, string>.Empty;
Microsoft.CodeAnalysis.Workspaces.MSBuild.UnitTests (2)
FileSet.cs (1)
21_fileMap = fileMap ?? ImmutableDictionary<string, object>.Empty;
VisualStudioMSBuildWorkspaceTests.cs (1)
3121await using var buildHostProcessManager = new BuildHostProcessManager(ImmutableDictionary<string, string>.Empty);
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (2)
Fakes\TestOptionSet.cs (1)
14public static new readonly TestOptionSet Empty = new(ImmutableDictionary<OptionKey, object?>.Empty);
Workspaces\TestWorkspace_XmlConsumption.cs (1)
658spans = ImmutableDictionary<string, ImmutableArray<TextSpan>>.Empty;
Microsoft.CodeAnalysis.Workspaces.UnitTests (14)
Formatter\FormatterTests.cs (1)
85var options = passExplicitOptions ? new TestOptionSet(ImmutableDictionary<OptionKey, object?>.Empty.
Options\DocumentOptionSetTests.cs (6)
21var underlyingSet = new TestOptionSet(ImmutableDictionary<OptionKey, object?>.Empty.Add( 51var underlyingSet = new TestOptionSet(ImmutableDictionary<OptionKey, object?>.Empty.Add( 73var underlyingSet = new TestOptionSet(ImmutableDictionary<OptionKey, object?>.Empty); 90var underlyingSet = new TestOptionSet(ImmutableDictionary<OptionKey, object?>.Empty); 122var underlyingSet = new TestOptionSet(ImmutableDictionary<OptionKey, object?>.Empty 152var underlyingSet = new TestOptionSet(ImmutableDictionary<OptionKey, object?>.Empty);
SolutionTests\SolutionTests.cs (4)
2289var solution2 = solution.WithFallbackAnalyzerOptions(ImmutableDictionary<string, StructuredAnalyzerConfigOptions>.Empty 2290.Add(LanguageNames.CSharp, StructuredAnalyzerConfigOptions.Create(new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty 2296var solution3 = solution2.WithFallbackAnalyzerOptions(ImmutableDictionary<string, StructuredAnalyzerConfigOptions>.Empty 2297.Add(LanguageNames.CSharp, StructuredAnalyzerConfigOptions.Create(new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty
UtilityTest\ImmutableDictionaryExtensionsTests.cs (3)
16var empty = ImmutableDictionary<int, int>.Empty; 32var emptyOrdinal = ImmutableDictionary<string, int>.Empty.WithComparers(keyComparer: StringComparer.Ordinal); 33var emptyIgnoreCase = ImmutableDictionary<string, int>.Empty.WithComparers(keyComparer: StringComparer.OrdinalIgnoreCase);
Microsoft.Interop.ComInterfaceGenerator (2)
Analyzers\AddGeneratedComClassFixer.cs (1)
59return ImmutableDictionary<string, Option>.Empty;
ComInterfaceGenerator.cs (1)
347ImmutableDictionary<string, string>.Empty.Add(GeneratorDiagnosticProperties.AddMarshalAsAttribute, "Error"),
Microsoft.Interop.LibraryImportGenerator (1)
Analyzers\DiagnosticReporter.cs (1)
21public void CreateAndReportDiagnostic(DiagnosticDescriptor descriptor, params object[] messageArgs) => _diagnosticFactory(descriptor, ImmutableDictionary<string, string>.Empty, messageArgs);
Microsoft.Interop.SourceGeneration (5)
Marshalling\AttributedMarshallingModelGeneratorResolver.cs (1)
25ImmutableDictionary<string, string>.Empty.Add(GeneratorDiagnosticProperties.AddDisableRuntimeMarshallingAttribute, GeneratorDiagnosticProperties.AddDisableRuntimeMarshallingAttribute);
Marshalling\BlittableMarshallerResolver.cs (1)
19ImmutableDictionary<string, string>.Empty.Add(GeneratorDiagnosticProperties.AddDisableRuntimeMarshallingAttribute, GeneratorDiagnosticProperties.AddDisableRuntimeMarshallingAttribute);
Marshalling\GeneratorDiagnostic.cs (1)
22public ImmutableDictionary<string, string> DiagnosticProperties { get; init; } = ImmutableDictionary<string, string>.Empty;
MarshallingAttributeInfo.cs (1)
143new CustomTypeMarshallers(ImmutableDictionary<MarshalMode, CustomTypeMarshallerData>.Empty.Add(
SafeHandleMarshallingInfoProvider.cs (1)
79Modes = ImmutableDictionary<MarshalMode, CustomTypeMarshallerData>.Empty
Microsoft.ML.Core (6)
Utilities\FuncMethodInfo1`1.cs (1)
31_instanceMethodInfo = ImmutableDictionary<Type, MethodInfo>.Empty;
Utilities\FuncMethodInfo1`2.cs (1)
32_instanceMethodInfo = ImmutableDictionary<Type, MethodInfo>.Empty;
Utilities\FuncMethodInfo1`3.cs (1)
33_instanceMethodInfo = ImmutableDictionary<Type, MethodInfo>.Empty;
Utilities\FuncMethodInfo2`3.cs (1)
33_instanceMethodInfo = ImmutableDictionary<(Type, Type), MethodInfo>.Empty;
Utilities\FuncMethodInfo3`2.cs (1)
32_instanceMethodInfo = ImmutableDictionary<(Type, Type, Type), MethodInfo>.Empty;
Utilities\FuncMethodInfo3`3.cs (1)
33_instanceMethodInfo = ImmutableDictionary<(Type, Type, Type), MethodInfo>.Empty;
Microsoft.ML.InternalCodeAnalyzer (1)
NameAnalyzer.cs (1)
35var props = ImmutableDictionary<string, string>.Empty
Microsoft.VisualStudio.LanguageServices (19)
Options\VisualStudioSettingsOptionPersister.cs (1)
35= ImmutableDictionary<string, (OptionKey2, string)>.Empty;
Packaging\PackageInstallerService.ProjectState.cs (1)
14public static readonly ProjectState Disabled = new(isEnabled: false, ImmutableDictionary<string, string>.Empty);
ProjectSystem\OpenTextBufferProvider.cs (1)
48private ImmutableDictionary<string, ITextBuffer> _monikerToTextBufferMap = ImmutableDictionary<string, ITextBuffer>.Empty.WithComparers(StringComparer.OrdinalIgnoreCase);
ProjectSystem\RuleSets\VisualStudioRuleSetManager.RuleSetFile.cs (1)
63_specificDiagnosticOptions = ImmutableDictionary<string, ReportDiagnostic>.Empty;
ProjectSystem\VisualStudioWorkspaceImpl.cs (3)
84private ImmutableDictionary<ProjectId, IVsHierarchy?> _projectToHierarchyMap = ImmutableDictionary<ProjectId, IVsHierarchy?>.Empty; 85private ImmutableDictionary<ProjectId, Guid> _projectToGuidMap = ImmutableDictionary<ProjectId, Guid>.Empty; 93private ImmutableDictionary<ProjectId, Func<string?>> _projectToRuleSetFilePath = ImmutableDictionary<ProjectId, Func<string?>>.Empty;
Snippets\SnippetExpansionClient.cs (1)
554var snippet = CreateMethodCallSnippet(methodName, includeMethod: true, ImmutableArray<IParameterSymbol>.Empty, ImmutableDictionary<string, string>.Empty);
TableDataSource\Suppression\VisualStudioDiagnosticListSuppressionStateService.cs (1)
286properties: ImmutableDictionary<string, string?>.Empty,
TableDataSource\Suppression\VisualStudioSuppressionFixService.cs (5)
241? ImmutableDictionary<Project, ImmutableArray<Diagnostic>>.Empty 438return builder != null ? builder.ToImmutable() : ImmutableDictionary<Document, ImmutableArray<Diagnostic>>.Empty; 457return projectDiagsBuilder != null ? projectDiagsBuilder.ToImmutable() : ImmutableDictionary<Project, ImmutableArray<Diagnostic>>.Empty; 484return ImmutableDictionary<Document, ImmutableArray<Diagnostic>>.Empty; 576return ImmutableDictionary<Project, ImmutableArray<Diagnostic>>.Empty;
Telemetry\Shared\AbstractAggregatingLog.cs (2)
31private ImmutableDictionary<string, (TAggregator aggregator, TelemetryEvent TelemetryEvent, object Lock)> _aggregations = ImmutableDictionary<string, (TAggregator, TelemetryEvent, object)>.Empty; 125_aggregations = ImmutableDictionary<string, (TAggregator, TelemetryEvent, object)>.Empty;
Telemetry\Shared\TelemetryLogProvider.cs (3)
23private ImmutableDictionary<FunctionId, VisualStudioTelemetryLog> _logs = ImmutableDictionary<FunctionId, VisualStudioTelemetryLog>.Empty; 28private ImmutableDictionary<FunctionId, AggregatingHistogramLog> _histogramLogs = ImmutableDictionary<FunctionId, AggregatingHistogramLog>.Empty; 33private ImmutableDictionary<FunctionId, AggregatingCounterLog> _counterLogs = ImmutableDictionary<FunctionId, AggregatingCounterLog>.Empty;
Microsoft.VisualStudio.LanguageServices.DevKit (5)
src\VisualStudio\Core\Def\Telemetry\Shared\AbstractAggregatingLog.cs (2)
31private ImmutableDictionary<string, (TAggregator aggregator, TelemetryEvent TelemetryEvent, object Lock)> _aggregations = ImmutableDictionary<string, (TAggregator, TelemetryEvent, object)>.Empty; 125_aggregations = ImmutableDictionary<string, (TAggregator, TelemetryEvent, object)>.Empty;
src\VisualStudio\Core\Def\Telemetry\Shared\TelemetryLogProvider.cs (3)
23private ImmutableDictionary<FunctionId, VisualStudioTelemetryLog> _logs = ImmutableDictionary<FunctionId, VisualStudioTelemetryLog>.Empty; 28private ImmutableDictionary<FunctionId, AggregatingHistogramLog> _histogramLogs = ImmutableDictionary<FunctionId, AggregatingHistogramLog>.Empty; 33private ImmutableDictionary<FunctionId, AggregatingCounterLog> _counterLogs = ImmutableDictionary<FunctionId, AggregatingCounterLog>.Empty;
Microsoft.VisualStudio.LanguageServices.LiveShare (1)
Client\RemoteLanguageServiceWorkspace.cs (1)
58private ImmutableDictionary<string, DocumentId> _openedDocs = ImmutableDictionary<string, DocumentId>.Empty;
Microsoft.VisualStudio.LanguageServices.UnitTests (4)
Diagnostics\ExternalDiagnosticUpdateSourceTests.vb (3)
49ImmutableDictionary(Of String, ImmutableArray(Of DiagnosticAnalyzer)).Empty.Add(LanguageNames.CSharp, ImmutableArray.Create(Of DiagnosticAnalyzer)(analyzer))) 95ImmutableDictionary(Of String, ImmutableArray(Of DiagnosticAnalyzer)).Empty.Add(LanguageNames.CSharp, ImmutableArray.Create(Of DiagnosticAnalyzer)(analyzer))) 179properties:=ImmutableDictionary(Of String, String).Empty,
ProjectSystemShim\ConvertedVisualBasicProjectOptionsTests.vb (1)
156ruleSetSpecificOptions = If(ruleSetSpecificOptions, ImmutableDictionary(Of String, ReportDiagnostic).Empty)
Microsoft.VisualStudio.LanguageServices.Xaml (1)
Features\InlineRename\XamlEditorInlineRenameService.cs (1)
37return Task.FromResult(ImmutableDictionary<string, ImmutableArray<(string filePath, string content)>>.Empty);
MSBuild (1)
CopyOnWriteDictionary.cs (1)
59_backing = ImmutableDictionary<string, V>.Empty;
Roslyn.VisualStudio.Next.UnitTests (8)
Options\VisualStudioSettingsOptionPersisterTests.cs (1)
81ImmutableDictionary<string, Lazy<IVisualStudioStorageReadFallback, OptionNameMetadata>>.Empty;
Remote\SnapshotSerializationTests.cs (3)
427var reference = new AnalyzerFileReference(location, new MockShadowCopyAnalyzerAssemblyLoader(ImmutableDictionary<string, string>.Empty.Add(location, file.Path))); 448var reference = new AnalyzerFileReference(location, new MockShadowCopyAnalyzerAssemblyLoader(ImmutableDictionary<string, string>.Empty.Add(location, file.Path))); 701return new AnalyzerFileReference(original, new MockShadowCopyAnalyzerAssemblyLoader(ImmutableDictionary<string, string>.Empty.Add(original, shadow.Path)));
Services\SolutionServiceTests.cs (4)
170return solution.WithFallbackAnalyzerOptions(ImmutableDictionary<string, StructuredAnalyzerConfigOptions>.Empty 171.Add(LanguageNames.CSharp, StructuredAnalyzerConfigOptions.Create(new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty 174.Add(LanguageNames.VisualBasic, StructuredAnalyzerConfigOptions.Create(new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty 177.Add(LanguageNames.FSharp, StructuredAnalyzerConfigOptions.Create(new DictionaryAnalyzerConfigOptions(ImmutableDictionary<string, string>.Empty
RunTests (3)
TestHistoryManager.cs (3)
50return ImmutableDictionary<string, TimeSpan>.Empty; 66return ImmutableDictionary<string, TimeSpan>.Empty; 75return ImmutableDictionary<string, TimeSpan>.Empty;
System.Collections.Immutable (10)
System\Collections\Immutable\ImmutableDictionary.cs (8)
23return ImmutableDictionary<TKey, TValue>.Empty; 37return ImmutableDictionary<TKey, TValue>.Empty.WithComparers(keyComparer); 52return ImmutableDictionary<TKey, TValue>.Empty.WithComparers(keyComparer, valueComparer); 64return ImmutableDictionary<TKey, TValue>.Empty.AddRange(items); 77return ImmutableDictionary<TKey, TValue>.Empty.WithComparers(keyComparer).AddRange(items); 91return ImmutableDictionary<TKey, TValue>.Empty.WithComparers(keyComparer, valueComparer).AddRange(items); 148return ImmutableDictionary<TKey, TValue>.Empty.WithComparers(keyComparer, valueComparer) 240return ImmutableDictionary<TKey, TValue>.Empty.WithComparers(keyComparer, valueComparer).AddRange(source);
System\Collections\Immutable\ImmutableDictionary_2.cs (2)
832return Empty._comparers == comparers 833? Empty
System.Windows.Forms.Analyzers.CSharp.Tests (8)
CompilerAnalyzerConfigOptionsProvider.cs (1)
20ImmutableDictionary<object, AnalyzerConfigOptions>.Empty,
Generators\ProjectFileReaderTests.cs (7)
50CompilerAnalyzerConfigOptionsProvider provider = new(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, configOptions); 76CompilerAnalyzerConfigOptionsProvider provider = new(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, configOptions); 114CompilerAnalyzerConfigOptionsProvider provider = new(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, configOptions); 151CompilerAnalyzerConfigOptionsProvider provider = new(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, configOptions); 173CompilerAnalyzerConfigOptionsProvider provider = new(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, configOptions); 193CompilerAnalyzerConfigOptionsProvider provider = new(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, configOptions); 211CompilerAnalyzerConfigOptionsProvider provider = new(ImmutableDictionary<object, AnalyzerConfigOptions>.Empty, configOptions);