1 write to Option
Microsoft.CodeAnalysis.Workspaces (1)
Options\OptionKey.cs (1)
37
Option
= option;
19 references to Option
Microsoft.CodeAnalysis.Workspaces (14)
Options\DocumentOptionSet.cs (1)
71
if (optionKey.
Option
is not IOption2 internallyDefinedOption)
Options\EmptyOptionSet.cs (1)
14
=> optionKey.
Option
.DefaultValue;
Options\OptionKey.cs (6)
43
return OptionEqual(
Option
, other.
Option
) && Language == other.Language;
60
var hash =
Option
?.GetHashCode() ?? 0;
72
if (
Option
is null)
77
var languageDisplay =
Option
.IsPerLanguage
81
return languageDisplay +
Option
.ToString();
Options\OptionSet.cs (2)
26
if (optionKey.
Option
is IOption2 { Definition.StorageMapping: { } mapping })
73
if (optionAndLanguage.
Option
is IOption2 { Definition.StorageMapping: { } mapping })
Options\SolutionOptionSet.cs (4)
54
value = (optionKey.
Option
is IOption2 internallyDefinedOption)
81
var internallyDefined = _changedOptionKeys.Where(key => key.
Option
is IOption2).SelectAsArray(key => KeyValuePairUtil.Create(new OptionKey2((IOption2)key.
Option
, key.Language), _values[key]));
82
var externallyDefined = _changedOptionKeys.Where(key => key.
Option
is not IOption2).SelectAsArray(key => KeyValuePairUtil.Create(key, _values[key]));
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (1)
Fakes\TestOptionSet.cs (1)
25
=> _values.TryGetValue(optionKey, out var value) ? value : optionKey.
Option
.DefaultValue;
Microsoft.CodeAnalysis.Workspaces.UnitTests (4)
WorkspaceServiceTests\GlobalOptionServiceTests.cs (4)
66
Assert.Equal(optionKey.
Option
.DefaultValue, optionSet.GetOption<int>(optionKey));
67
Assert.Equal(perLanguageOptionKey.
Option
.DefaultValue, optionSet.GetOption<int>(perLanguageOptionKey));
99
Assert.Equal(perLanguageOptionKey.
Option
.DefaultValue, optionSet.GetOption<string>(perLanguageOptionKey));
109
Assert.Equal(perLanguageOptionKey.
Option
.DefaultValue, oldSolution2.Options.GetOption<string>(perLanguageOptionKey));