22 references to SpecializedCollections
Microsoft.CodeAnalysis.Workspaces (22)
Diagnostics\DiagnosticAnalysisResult.cs (1)
304var documents = SpecializedCollections.EmptyEnumerable<DocumentId>();
FindSymbols\FindReferences\DependentTypeFinder.cs (1)
429return SpecializedCollections.EmptySet<ProjectId>();
Formatting\Formatter.cs (1)
308? SpecializedCollections.EmptyList<TextChange>()
Recommendations\AbstractRecommendationService.cs (1)
56return SpecializedCollections.EmptySet<INamedTypeSymbol>();
src\Compilers\Core\Portable\InternalUtilities\EnumerableExtensions.cs (4)
85return SpecializedCollections.EmptyBoxedImmutableArray<T>(); 90return array.IsDefaultOrEmpty ? SpecializedCollections.EmptyBoxedImmutableArray<T>() : (IReadOnlyList<T>)items; 95return SpecializedCollections.EmptyBoxedImmutableArray<T>(); 345return SpecializedCollections.EmptyEnumerable<T>();
src\Compilers\Core\Portable\InternalUtilities\SetWithInsertionOrder.cs (2)
90=> _elements is null ? SpecializedCollections.EmptyEnumerator<T>() : ((IEnumerable<T>)_elements).GetEnumerator(); 99=> (IReadOnlySet<T>?)_set ?? SpecializedCollections.EmptyReadOnlySet<T>();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.cs (2)
37var operations = SpecializedCollections.SingletonEnumerable(rootOperation); 51var operations = SpecializedCollections.SingletonEnumerable(localFunctionOperation);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\FlowAnalysis\SymbolUsageAnalysis\SymbolUsageAnalysis.DataFlowAnalyzer.cs (1)
155var operations = SpecializedCollections.SingletonEnumerable(basicBlock.BranchValue);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\IReadOnlyDictionaryExtensions.cs (1)
27case T s: return SpecializedCollections.SingletonEnumerable(s);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\SpecializedTasks.cs (3)
187public static readonly Task<IEnumerable<T>> EmptyEnumerable = Task.FromResult<IEnumerable<T>>(SpecializedCollections.EmptyEnumerable<T>()); 189public static readonly Task<IList<T>> EmptyList = Task.FromResult(SpecializedCollections.EmptyList<T>()); 190public static readonly Task<IReadOnlyList<T>> EmptyReadOnlyList = Task.FromResult(SpecializedCollections.EmptyReadOnlyList<T>());
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\Symbols\CodeGenerationNamespaceInfo.cs (1)
26var info = new CodeGenerationNamespaceInfo(imports ?? SpecializedCollections.EmptyList<ISymbol>());
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\CodeGeneration\Symbols\CodeGenerationNamespaceSymbol.cs (1)
16private readonly IList<INamespaceOrTypeSymbol> _members = members ?? SpecializedCollections.EmptyList<INamespaceOrTypeSymbol>();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\DocumentExtensions.cs (1)
182ignoreErrorCode ??= SpecializedCollections.EmptyList<string>();
Workspace\Solution\ProjectInfo.cs (1)
255analyzerConfigDocuments: SpecializedCollections.EmptyBoxedImmutableArray<DocumentInfo>(),
Workspace\Solution\SolutionState.cs (1)
114projectIds: SpecializedCollections.EmptyBoxedImmutableArray<ProjectId>(),