17 references to CodeStyleHelpers
Microsoft.CodeAnalysis.Workspaces (17)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CodeStyleOptions2.cs (8)
183if (CodeStyleHelpers.TryGetCodeStyleValueAndOptionalNotification(str, defaultValue.Notification, out var value, out var notification)) 194return $"{value}{CodeStyleHelpers.GetEditorConfigStringNotificationPart(option, defaultValue)}"; 212if (CodeStyleHelpers.TryGetCodeStyleValueAndOptionalNotification(str, defaultValue.Notification, out var value, out var notificationOpt)) 223return $"{s_accessibilityModifiersRequiredMap.GetKeyOrDefault(option.Value)}{CodeStyleHelpers.GetEditorConfigStringNotificationPart(option, defaultValue)}"; 258if (CodeStyleHelpers.TryGetCodeStyleValueAndOptionalNotification(str, defaultValue.Notification, out var value, out var notification)) 270return $"{value}{CodeStyleHelpers.GetEditorConfigStringNotificationPart(option, defaultValue)}"; 310if (CodeStyleHelpers.TryGetCodeStyleValueAndOptionalNotification(str, defaultValue.Notification, out var value, out var notification)) 324return $"{value}{CodeStyleHelpers.GetEditorConfigStringNotificationPart(option, defaultValue)}";
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\CollectionExpressionPreference.cs (2)
37return $"{prefix}{CodeStyleHelpers.GetEditorConfigStringNotificationPart(value, defaultValue)}"; 43if (CodeStyleHelpers.TryGetCodeStyleValueAndOptionalNotification(
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\OperatorPlacementWhenWrappingPreference.cs (1)
24if (CodeStyleHelpers.TryGetCodeStyleValue(optionString, out var value))
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\CodeStyle\VisualBasic\VisualBasicCodeStyleOptions.cs (2)
49CodeStyleHelpers.GetUnusedValuePreferenceSerializer); 55CodeStyleHelpers.GetUnusedValuePreferenceSerializer);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Options\EditorConfigValueSerializer.cs (4)
92=> new(parseValue: str => CodeStyleHelpers.TryParseBoolEditorConfigCodeStyleOption(str, defaultValue, out var result) ? result : new Optional<CodeStyleOption2<bool>>(), 93serializeValue: value => (value.Value ? "true" : "false") + CodeStyleHelpers.GetEditorConfigStringNotificationPart(value, defaultValue)); 96=> new(parseValue: str => CodeStyleHelpers.TryParseStringEditorConfigCodeStyleOption(str, defaultValue, out var result) ? result : new Optional<CodeStyleOption2<string>>(), 97serializeValue: value => value.Value.ToLowerInvariant() + CodeStyleHelpers.GetEditorConfigStringNotificationPart(value, defaultValue));