73 references to ToImmutableAndFree
Microsoft.CodeAnalysis.Workspaces (73)
Classification\Classifier.cs (1)
145
return parts.
ToImmutableAndFree
();
CodeCleanup\AbstractCodeCleanerService.cs (1)
143
return builder.
ToImmutableAndFree
();
CodeFixes\FixAllOccurrences\FixAllState.FixMultipleDiagnosticProvider.cs (1)
56
return Task.FromResult<IEnumerable<Diagnostic>>(allDiagnosticsBuilder.
ToImmutableAndFree
());
Diagnostics\DiagnosticAnalysisResult.cs (1)
151
others: diagnosticsWithoutDocumentId.
ToImmutableAndFree
(),
Diagnostics\Extensions.cs (1)
32
return result.
ToImmutableAndFree
();
Diagnostics\SkippedHostAnalyzersInfo.cs (1)
164
skippedDiagnosticIdsForAnalyzer = skippedDiagnosticIdsBuilder.
ToImmutableAndFree
();
FindSymbols\Declarations\DeclarationFinder_AllDeclarations.cs (1)
173
return result.
ToImmutableAndFree
();
FindSymbols\FindReferences\BaseTypeFinder.cs (1)
91
return typesBuilder.
ToImmutableAndFree
();
FindSymbols\SymbolTree\SymbolTreeInfo_Metadata.cs (1)
733
return unsortedNodes.
ToImmutableAndFree
();
Rename\ConflictEngine\DeclarationConflictHelpers.cs (3)
74
return builder.
ToImmutableAndFree
();
114
resultBuilder.Add(signatureBuilder.
ToImmutableAndFree
());
115
return resultBuilder.
ToImmutableAndFree
();
Rename\SymbolicRenameLocations.ReferenceProcessing.cs (2)
184
return results.
ToImmutableAndFree
();
229
return results.
ToImmutableAndFree
();
Serialization\SerializationExtensions.cs (1)
86
return builder.
ToImmutableAndFree
();
Shared\Extensions\ILanguageMetadataExtensions.cs (2)
41
return builder.Select(kvp => KeyValuePairUtil.Create(kvp.Key, kvp.Value.
ToImmutableAndFree
())).ToImmutableDictionary();
61
return map.ToImmutableDictionary(kvp => kvp.Key, kvp => kvp.Value.
ToImmutableAndFree
());
Shared\Extensions\ISolutionExtensions.cs (1)
36
return results.
ToImmutableAndFree
();
Shared\Extensions\TokenSemanticInfo.cs (1)
47
return result.
ToImmutableAndFree
();
src\Compilers\Core\Portable\Collections\ArrayBuilderExtensions.cs (4)
97
return builder.
ToImmutableAndFree
();
137
return builder.
ToImmutableAndFree
();
177
return builder.
ToImmutableAndFree
();
224
return builder?.
ToImmutableAndFree
() ?? ImmutableArray<T>.Empty;
src\Compilers\Core\Portable\Collections\DictionaryExtensions.cs (1)
97
result.Add(key, values.
ToImmutableAndFree
());
src\Compilers\Core\Portable\Collections\ImmutableArrayExtensions.cs (16)
197
return builder.
ToImmutableAndFree
();
226
return builder.
ToImmutableAndFree
();
256
return builder.
ToImmutableAndFree
();
276
return builder.
ToImmutableAndFree
();
296
return builder.
ToImmutableAndFree
();
318
return builder.
ToImmutableAndFree
();
342
return builder.
ToImmutableAndFree
();
366
return builder.
ToImmutableAndFree
();
390
return builder.
ToImmutableAndFree
();
415
return builder.
ToImmutableAndFree
();
477
return builder.
ToImmutableAndFree
();
529
return builder.
ToImmutableAndFree
();
604
return builder.
ToImmutableAndFree
();
879
return builder.
ToImmutableAndFree
();
1193
return builder.
ToImmutableAndFree
();
1261
return builder.
ToImmutableAndFree
();
src\Compilers\Core\Portable\InternalUtilities\EnumerableExtensions.cs (11)
364
return builder.
ToImmutableAndFree
();
381
return builder.
ToImmutableAndFree
();
425
return builder.
ToImmutableAndFree
();
437
return builder.
ToImmutableAndFree
();
450
return builder.
ToImmutableAndFree
();
463
return builder.
ToImmutableAndFree
();
475
return builder.
ToImmutableAndFree
();
490
return builder.
ToImmutableAndFree
();
505
return builder.
ToImmutableAndFree
();
520
return builder.
ToImmutableAndFree
();
532
return builder.
ToImmutableAndFree
();
src\Compilers\Core\Portable\Text\TextChangeRangeExtensions.cs (1)
338
return builder.
ToImmutableAndFree
();
src\Dependencies\PooledObjects\ArrayBuilder.cs (3)
380
return tmp.
ToImmutableAndFree
();
553
dictionary.Add(pair.Key, pair.Value.
ToImmutableAndFree
());
721
return result.
ToImmutableAndFree
();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ICompilationExtensions.cs (2)
39
return builder.
ToImmutableAndFree
();
69
return builder.
ToImmutableAndFree
();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Extensions\ISymbolExtensions.cs (2)
447
return results.
ToImmutableAndFree
();
470
return results.
ToImmutableAndFree
();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\EditorConfig\EditorConfigNamingStyleParser_SymbolSpec.cs (3)
184
return builder.
ToImmutableAndFree
();
243
return builder.
ToImmutableAndFree
();
292
return builder.
ToImmutableAndFree
();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\NamingStyles\Serialization\SymbolSpecification.cs (1)
308
return applicableSymbolKindList.
ToImmutableAndFree
();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\PooledBuilderExtensions.cs (4)
36
dictionary.Add(key, items.
ToImmutableAndFree
());
50
result.Add(key, items.
ToImmutableAndFree
());
77
return builders[0].
ToImmutableAndFree
();
88
return result.
ToImmutableAndFree
();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\SyntaxGeneratorExtensions_CreateEqualsMethod.cs (1)
319
return statements.
ToImmutableAndFree
();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Extensions\SyntaxGeneratorExtensions_CreateGetHashCodeMethod.cs (3)
38
return result.
ToImmutableAndFree
();
72
return statements.
ToImmutableAndFree
();
169
return statements.
ToImmutableAndFree
();
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Utilities\NameGenerator.cs (1)
51
return result.
ToImmutableAndFree
();
Workspace\Solution\SolutionCompilationState.cs (1)
1647
missingDocumentStates.SelectAsArray(kvp => (kvp.Key, kvp.Value.
ToImmutableAndFree
())),