31 references to KeyValuePairUtil
Microsoft.CodeAnalysis.Workspaces (31)
CodeFixes\FixAllOccurrences\FixAllContext.DiagnosticProvider.cs (1)
82return ImmutableDictionary.CreateRange([KeyValuePairUtil.Create(project, diagnostics)]);
CodeRefactorings\FixAllOccurences\FixAllState.cs (1)
103return spansByDocument.Select(kvp => KeyValuePairUtil.Create(kvp.Key, new Optional<ImmutableArray<TextSpan>>(kvp.Value)))
Differencing\LongestCommonSubsequence.cs (1)
288yield return KeyValuePairUtil.Create(xEnd, yEnd);
LanguageServices\FixAllSpanMappingService\AbstractFixAllSpanMappingService.cs (2)
40return ImmutableDictionary.CreateRange([KeyValuePairUtil.Create(document, ImmutableArray.Create(decl.FullSpan))]); 66return ImmutableDictionary.CreateRange([KeyValuePairUtil.Create(document, ImmutableArray.Create(decl.FullSpan))]);
Log\AbstractLogAggregator.cs (1)
42=> _map.Select(static kvp => KeyValuePairUtil.Create((TKey)kvp.Key, kvp.Value)).GetEnumerator();
Options\GlobalOptionService.cs (1)
184=> SetGlobalOptions(OneOrMany.Create(KeyValuePairUtil.Create(optionKey, value)));
Options\SolutionOptionSet.cs (2)
81var internallyDefined = _changedOptionKeys.Where(key => key.Option is IOption2).SelectAsArray(key => KeyValuePairUtil.Create(new OptionKey2((IOption2)key.Option, key.Language), _values[key])); 82var externallyDefined = _changedOptionKeys.Where(key => key.Option is not IOption2).SelectAsArray(key => KeyValuePairUtil.Create(key, _values[key]));
Serialization\AbstractOptionsSerializationService.cs (2)
145specificDiagnosticOptionsList.Add(KeyValuePairUtil.Create(key, value)); 231featuresList.Add(KeyValuePairUtil.Create(key, value));
Shared\Extensions\ILanguageMetadataExtensions.cs (1)
41return builder.Select(kvp => KeyValuePairUtil.Create(kvp.Key, kvp.Value.ToImmutableAndFree())).ToImmutableDictionary();
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleHelpers.cs (2)
160KeyValuePairUtil.Create("discard_variable", UnusedValuePreference.DiscardVariable), 161KeyValuePairUtil.Create("unused_local_variable", UnusedValuePreference.UnusedLocalVariable),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOptions2.cs (10)
172KeyValuePairUtil.Create("non_public", UnusedParametersPreference.NonPublicMethods), 173KeyValuePairUtil.Create("all", UnusedParametersPreference.AllMethods), 200KeyValuePairUtil.Create("never", CodeStyle.AccessibilityModifiersRequired.Never), 201KeyValuePairUtil.Create("always", CodeStyle.AccessibilityModifiersRequired.Always), 202KeyValuePairUtil.Create("for_non_interface_members", CodeStyle.AccessibilityModifiersRequired.ForNonInterfaceMembers), 203KeyValuePairUtil.Create("omit_if_default", CodeStyle.AccessibilityModifiersRequired.OmitIfDefault), 246KeyValuePairUtil.Create("always_for_clarity", ParenthesesPreference.AlwaysForClarity), 247KeyValuePairUtil.Create("never_if_unnecessary", ParenthesesPreference.NeverIfUnnecessary), 299KeyValuePairUtil.Create("always", ForEachExplicitCastInSourcePreference.Always), 300KeyValuePairUtil.Create("when_strongly_typed", ForEachExplicitCastInSourcePreference.WhenStronglyTyped),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer.cs (1)
129.AddRange(alternativeEntries.Select(static p => KeyValuePairUtil.Create(p.name, p.value)));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\BidirectionalMap.cs (3)
25backwardMap: ImmutableDictionary.CreateRange(valueComparer, pairs.Select(static p => KeyValuePairUtil.Create(p.Value, p.Key)))) 30: this(forwardMap: ImmutableDictionary.CreateRange(keyComparer, pairs.Select(static p => KeyValuePairUtil.Create(p.key, p.value))), 31backwardMap: ImmutableDictionary.CreateRange(valueComparer, pairs.Select(static p => KeyValuePairUtil.Create(p.value, p.key))))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\EnumerableConditionalWeakTable.cs (1)
124yield return KeyValuePairUtil.Create(box.Key, box.Value);
Workspace\Solution\SolutionState.cs (1)
1192var map = projectStates.Values.Select(state => KeyValuePairUtil.Create(
Workspace\Solution\TextDocumentStates.cs (1)
153States.AddRange(states.Select(state => KeyValuePairUtil.Create(state.Id, state))),