From: Stephen Toub Date: Mon, 25 Jun 2018 23:54:41 +0000 (-0400) Subject: Simplify built-in types across corefx (dotnet/corefxdotnet/coreclr#30656) X-Git-Tag: submit/tizen/20210909.063632~11030^2~4511 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9530d3f34100dfc7f75cb35abdb4f507509b5700;p=platform%2Fupstream%2Fdotnet%2Fruntime.git Simplify built-in types across corefx (dotnet/corefxdotnet/coreclr#30656) Signed-off-by: dotnet-bot Commit migrated from https://github.com/dotnet/coreclr/commit/38125912cdde6b8bdf87154139189cf55b235f62 --- diff --git a/src/libraries/System.Private.CoreLib/src/Interop/Unix/System.Globalization.Native/Interop.Locale.cs b/src/libraries/System.Private.CoreLib/src/Interop/Unix/System.Globalization.Native/Interop.Locale.cs index 9ef41de..b6f5fbe 100644 --- a/src/libraries/System.Private.CoreLib/src/Interop/Unix/System.Globalization.Native/Interop.Locale.cs +++ b/src/libraries/System.Private.CoreLib/src/Interop/Unix/System.Globalization.Native/Interop.Locale.cs @@ -35,6 +35,6 @@ internal static partial class Interop internal static extern unsafe bool GetLocaleInfoGroupingSizes(string localeName, uint localeGroupingData, ref int primaryGroupSize, ref int secondaryGroupSize); [DllImport(Libraries.GlobalizationNative, CharSet = CharSet.Unicode, EntryPoint = "GlobalizationNative_GetLocales")] - internal static extern unsafe int GetLocales([Out] Char[] value, int valueLength); + internal static extern unsafe int GetLocales([Out] char[] value, int valueLength); } } diff --git a/src/libraries/System.Private.CoreLib/src/System/Globalization/CalendarData.Unix.cs b/src/libraries/System.Private.CoreLib/src/System/Globalization/CalendarData.Unix.cs index 1d37926..61e0691 100644 --- a/src/libraries/System.Private.CoreLib/src/System/Globalization/CalendarData.Unix.cs +++ b/src/libraries/System.Private.CoreLib/src/System/Globalization/CalendarData.Unix.cs @@ -32,7 +32,7 @@ namespace System.Globalization internal partial class CalendarData { - private bool LoadCalendarDataFromSystem(String localeName, CalendarId calendarId) + private bool LoadCalendarDataFromSystem(string localeName, CalendarId calendarId) { bool result = true; result &= GetCalendarInfo(localeName, calendarId, CalendarDataType.NativeName, out this.sNativeName); diff --git a/src/libraries/System.Private.CoreLib/src/System/Globalization/CompareInfo.Unix.cs b/src/libraries/System.Private.CoreLib/src/System/Globalization/CompareInfo.Unix.cs index 2c46843..90e9eba 100644 --- a/src/libraries/System.Private.CoreLib/src/System/Globalization/CompareInfo.Unix.cs +++ b/src/libraries/System.Private.CoreLib/src/System/Globalization/CompareInfo.Unix.cs @@ -722,7 +722,7 @@ namespace System.Globalization } } - private unsafe SortKey CreateSortKey(String source, CompareOptions options) + private unsafe SortKey CreateSortKey(string source, CompareOptions options) { Debug.Assert(!_invariantMode); diff --git a/src/libraries/System.Private.CoreLib/src/System/Globalization/CultureData.Unix.cs b/src/libraries/System.Private.CoreLib/src/System/Globalization/CultureData.Unix.cs index 933087d..4b21f2e 100644 --- a/src/libraries/System.Private.CoreLib/src/System/Globalization/CultureData.Unix.cs +++ b/src/libraries/System.Private.CoreLib/src/System/Globalization/CultureData.Unix.cs @@ -227,19 +227,19 @@ namespace System.Globalization return this.GetLocaleInfo(LocaleNumberData.FirstDayOfWeek); } - private String[] GetTimeFormats() + private string[] GetTimeFormats() { string format = GetTimeFormatString(false); return new string[] { format }; } - private String[] GetShortTimeFormats() + private string[] GetShortTimeFormats() { string format = GetTimeFormatString(true); return new string[] { format }; } - private static CultureData GetCultureDataFromRegionName(String regionName) + private static CultureData GetCultureDataFromRegionName(string regionName) { // no support to lookup by region name, other than the hard-coded list in CultureData return null; @@ -371,7 +371,7 @@ namespace System.Globalization return Array.Empty(); } - Char [] chars = new Char[bufferLength]; + char [] chars = new char[bufferLength]; bufferLength = Interop.Globalization.GetLocales(chars, bufferLength); if (bufferLength <= 0) @@ -394,7 +394,7 @@ namespace System.Globalization int length = (int) chars[index++]; if (index + length <= bufferLength) { - CultureInfo ci = CultureInfo.GetCultureInfo(new String(chars, index, length)); + CultureInfo ci = CultureInfo.GetCultureInfo(new string(chars, index, length)); if ((enumNeutrals && ci.IsNeutralCulture) || (enumSpecificss && !ci.IsNeutralCulture)) { list.Add(ci); diff --git a/src/libraries/System.Private.CoreLib/src/System/Globalization/JapaneseCalendar.WinRT.cs b/src/libraries/System.Private.CoreLib/src/System/Globalization/JapaneseCalendar.WinRT.cs index 6a9df97..818cb5b 100644 --- a/src/libraries/System.Private.CoreLib/src/System/Globalization/JapaneseCalendar.WinRT.cs +++ b/src/libraries/System.Private.CoreLib/src/System/Globalization/JapaneseCalendar.WinRT.cs @@ -46,7 +46,7 @@ namespace System.Globalization // PAL Layer ends here - private static string[] JapaneseErasEnglishNames = new String[] { "M", "T", "S", "H" }; + private static string[] JapaneseErasEnglishNames = new string[] { "M", "T", "S", "H" }; private static string GetJapaneseEnglishEraName(int era) {