38 references to KeyValuePair
Microsoft.CodeAnalysis.CodeStyle (17)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleHelpers.cs (2)
161
KeyValuePair
.Create("discard_variable", UnusedValuePreference.DiscardVariable),
162
KeyValuePair
.Create("unused_local_variable", UnusedValuePreference.UnusedLocalVariable),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOptions2.cs (10)
173
KeyValuePair
.Create("non_public", UnusedParametersPreference.NonPublicMethods),
174
KeyValuePair
.Create("all", UnusedParametersPreference.AllMethods),
201
KeyValuePair
.Create("never", CodeStyle.AccessibilityModifiersRequired.Never),
202
KeyValuePair
.Create("always", CodeStyle.AccessibilityModifiersRequired.Always),
203
KeyValuePair
.Create("for_non_interface_members", CodeStyle.AccessibilityModifiersRequired.ForNonInterfaceMembers),
204
KeyValuePair
.Create("omit_if_default", CodeStyle.AccessibilityModifiersRequired.OmitIfDefault),
247
KeyValuePair
.Create("always_for_clarity", ParenthesesPreference.AlwaysForClarity),
248
KeyValuePair
.Create("never_if_unnecessary", ParenthesesPreference.NeverIfUnnecessary),
300
KeyValuePair
.Create("always", ForEachExplicitCastInSourcePreference.Always),
301
KeyValuePair
.Create("when_strongly_typed", ForEachExplicitCastInSourcePreference.WhenStronglyTyped),
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer.cs (1)
131
.AddRange(alternativeEntries.Select(static p =>
KeyValuePair
.Create(p.name, p.value)));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\BidirectionalMap.cs (3)
25
backwardMap: ImmutableDictionary.CreateRange(valueComparer, pairs.Select(static p =>
KeyValuePair
.Create(p.Value, p.Key))))
30
: this(forwardMap: ImmutableDictionary.CreateRange(keyComparer, pairs.Select(static p =>
KeyValuePair
.Create(p.key, p.value))),
31
backwardMap: ImmutableDictionary.CreateRange(valueComparer, pairs.Select(static p =>
KeyValuePair
.Create(p.value, p.key))))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\EnumerableConditionalWeakTable.cs (1)
125
yield return
KeyValuePair
.Create(box.Key, box.Value);
Microsoft.CodeAnalysis.CSharp.CodeStyle (20)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\Formatting\CSharpFormattingOptions2.cs (20)
24
KeyValuePair
.Create("expressions", SpacePlacementWithinParentheses.Expressions),
25
KeyValuePair
.Create("type_casts", SpacePlacementWithinParentheses.TypeCasts),
26
KeyValuePair
.Create("control_flow_statements", SpacePlacementWithinParentheses.ControlFlowStatements),
31
KeyValuePair
.Create("ignore", BinaryOperatorSpacingOptionsInternal.Ignore),
32
KeyValuePair
.Create("none", BinaryOperatorSpacingOptionsInternal.Remove),
33
KeyValuePair
.Create("before_and_after", BinaryOperatorSpacingOptionsInternal.Single),
38
KeyValuePair
.Create("flush_left", LabelPositionOptionsInternal.LeftMost),
39
KeyValuePair
.Create("no_change", LabelPositionOptionsInternal.NoIndent),
40
KeyValuePair
.Create("one_less_than_current", LabelPositionOptionsInternal.OneLess),
45
KeyValuePair
.Create("object_collection_array_initalizers", NewLineBeforeOpenBracePlacement.ObjectCollectionArrayInitializers),
50
KeyValuePair
.Create("all", NewLineBeforeOpenBracePlacement.All),
51
KeyValuePair
.Create("accessors", NewLineBeforeOpenBracePlacement.Accessors),
52
KeyValuePair
.Create("types", NewLineBeforeOpenBracePlacement.Types),
53
KeyValuePair
.Create("methods", NewLineBeforeOpenBracePlacement.Methods),
54
KeyValuePair
.Create("properties", NewLineBeforeOpenBracePlacement.Properties),
55
KeyValuePair
.Create("anonymous_methods", NewLineBeforeOpenBracePlacement.AnonymousMethods),
56
KeyValuePair
.Create("control_blocks", NewLineBeforeOpenBracePlacement.ControlBlocks),
57
KeyValuePair
.Create("anonymous_types", NewLineBeforeOpenBracePlacement.AnonymousTypes),
58
KeyValuePair
.Create("object_collection_array_initializers", NewLineBeforeOpenBracePlacement.ObjectCollectionArrayInitializers),
59
KeyValuePair
.Create("lambdas", NewLineBeforeOpenBracePlacement.LambdaExpressionBody),
Microsoft.CodeAnalysis.CSharp.CodeStyle.UnitTests (1)
src\Analyzers\CSharp\Tests\MakeFieldReadonly\MakeFieldReadonlyTests.cs (1)
25
private static readonly ParseOptions s_strictFeatureFlag = CSharpParseOptions.Default.WithFeatures([
KeyValuePair
.Create("strict", "true")]);