Prefix enums, remove DLLEXPORT from GetResultCode
authorFilip Navara <filip.navara@gmail.com>
Sun, 3 Feb 2019 09:59:55 +0000 (10:59 +0100)
committerFilip Navara <filip.navara@gmail.com>
Sun, 3 Feb 2019 10:18:09 +0000 (11:18 +0100)
Move SortHandle out of public API header, it is opaque structure

src/corefx/System.Globalization.Native/pal_calendarData.c
src/corefx/System.Globalization.Native/pal_calendarData.h
src/corefx/System.Globalization.Native/pal_collation.c
src/corefx/System.Globalization.Native/pal_collation.h
src/corefx/System.Globalization.Native/pal_errors.h
src/corefx/System.Globalization.Native/pal_localeNumberData.c
src/corefx/System.Globalization.Native/pal_localeNumberData.h
src/corefx/System.Globalization.Native/pal_localeStringData.c
src/corefx/System.Globalization.Native/pal_localeStringData.h
src/corefx/System.Globalization.Native/pal_timeZoneInfo.c
src/corefx/System.Globalization.Native/pal_timeZoneInfo.h

index 307d078..be0cc9b 100644 (file)
@@ -193,9 +193,9 @@ ResultCode GlobalizationNative_GetCalendarInfo(
 
     switch (dataType)
     {
-        case NativeName:
+        case CalendarData_NativeName:
             return GetNativeCalendarName(locale, calendarId, result, resultCapacity);
-        case MonthDay:
+        case CalendarData_MonthDay:
             return GetMonthDayPattern(locale, result, resultCapacity);
         default:
             assert(FALSE);
@@ -488,27 +488,27 @@ int32_t GlobalizationNative_EnumCalendarInfo(EnumCalendarInfoCallback callback,
 
     switch (dataType)
     {
-        case ShortDates:
+        case CalendarData_ShortDates:
             // ShortDates to map kShort and kMedium in ICU, but also adding the "yMd"
             // skeleton as well, as this closely matches what is used on Windows
             return InvokeCallbackForDatePattern(locale, UDAT_SHORT, callback, context) &&
                    InvokeCallbackForDatePattern(locale, UDAT_MEDIUM, callback, context) &&
                    InvokeCallbackForDateTimePattern(locale, UDAT_YEAR_NUM_MONTH_DAY_UCHAR, callback, context);
-        case LongDates:
+        case CalendarData_LongDates:
             // LongDates map to kFull and kLong in ICU.
             return InvokeCallbackForDatePattern(locale, UDAT_FULL, callback, context) &&
                    InvokeCallbackForDatePattern(locale, UDAT_LONG, callback, context);
-        case YearMonths:
+        case CalendarData_YearMonths:
             return InvokeCallbackForDateTimePattern(locale, UDAT_YEAR_MONTH_UCHAR, callback, context);
-        case DayNames:
+        case CalendarData_DayNames:
             return EnumSymbols(locale, calendarId, UDAT_STANDALONE_WEEKDAYS, 1, callback, context);
-        case AbbrevDayNames:
+        case CalendarData_AbbrevDayNames:
             return EnumSymbols(locale, calendarId, UDAT_STANDALONE_SHORT_WEEKDAYS, 1, callback, context);
-        case MonthNames:
+        case CalendarData_MonthNames:
             return EnumSymbols(locale, calendarId, UDAT_STANDALONE_MONTHS, 0, callback, context);
-        case AbbrevMonthNames:
+        case CalendarData_AbbrevMonthNames:
             return EnumSymbols(locale, calendarId, UDAT_STANDALONE_SHORT_MONTHS, 0, callback, context);
-        case SuperShortDayNames:
+        case CalendarData_SuperShortDayNames:
             // UDAT_STANDALONE_SHORTER_WEEKDAYS was added in ICU 51, and CentOS 7 currently uses ICU 50.
             // fallback to UDAT_STANDALONE_NARROW_WEEKDAYS in that case.
 #if HAVE_UDAT_STANDALONE_SHORTER_WEEKDAYS
@@ -516,13 +516,13 @@ int32_t GlobalizationNative_EnumCalendarInfo(EnumCalendarInfoCallback callback,
 #else
             return EnumSymbols(locale, calendarId, UDAT_STANDALONE_NARROW_WEEKDAYS, 1, callback, context);
 #endif
-        case MonthGenitiveNames:
+        case CalendarData_MonthGenitiveNames:
             return EnumSymbols(locale, calendarId, UDAT_MONTHS, 0, callback, context);
-        case AbbrevMonthGenitiveNames:
+        case CalendarData_AbbrevMonthGenitiveNames:
             return EnumSymbols(locale, calendarId, UDAT_SHORT_MONTHS, 0, callback, context);
-        case EraNames:
+        case CalendarData_EraNames:
             return EnumSymbols(locale, calendarId, UDAT_ERAS, 0, callback, context);
-        case AbbrevEraNames:
+        case CalendarData_AbbrevEraNames:
             return EnumAbbrevEraNames(locale, calendarId, callback, context);
         default:
             assert(FALSE);
index 394c612..e0d5ac5 100644 (file)
@@ -48,21 +48,21 @@ typedef uint16_t CalendarId;
 */
 typedef enum
 {
-    Uninitialized = 0,
-    NativeName = 1,
-    MonthDay = 2,
-    ShortDates = 3,
-    LongDates = 4,
-    YearMonths = 5,
-    DayNames = 6,
-    AbbrevDayNames = 7,
-    MonthNames = 8,
-    AbbrevMonthNames = 9,
-    SuperShortDayNames = 10,
-    MonthGenitiveNames = 11,
-    AbbrevMonthGenitiveNames = 12,
-    EraNames = 13,
-    AbbrevEraNames = 14,
+    CalendarData_Uninitialized = 0,
+    CalendarData_NativeName = 1,
+    CalendarData_MonthDay = 2,
+    CalendarData_ShortDates = 3,
+    CalendarData_LongDates = 4,
+    CalendarData_YearMonths = 5,
+    CalendarData_DayNames = 6,
+    CalendarData_AbbrevDayNames = 7,
+    CalendarData_MonthNames = 8,
+    CalendarData_AbbrevMonthNames = 9,
+    CalendarData_SuperShortDayNames = 10,
+    CalendarData_MonthGenitiveNames = 11,
+    CalendarData_AbbrevMonthGenitiveNames = 12,
+    CalendarData_EraNames = 13,
+    CalendarData_AbbrevEraNames = 14,
 } CalendarDataType;
 
 // the function pointer definition for the callback used in EnumCalendarInfo
index a56aa09..a0ce96d 100644 (file)
@@ -32,9 +32,24 @@ const int32_t CompareOptionsIgnoreWidth = 0x10;
 // change ICU's default behavior here isn't really justified unless someone has a strong reason
 // for !StringSort to behave differently.
 
+typedef struct { int32_t key; UCollator* UCollator; } TCollatorMap;
+
+/*
+ * For increased performance, we cache the UCollator objects for a locale and
+ * share them across threads. This is safe (and supported in ICU) if we ensure
+ * multiple threads are only ever dealing with const UCollators.
+ */
+struct SortHandle
+{
+    UCollator* regular;
+    TCollatorMap* collatorsPerOption;
+    pthread_mutex_t collatorsLockObject;
+    void* pRoot;
+};
+
 typedef struct { UChar* items; size_t capacity; size_t size; } UCharList;
 
-int TreeComparer(const void* left, const void* right)
+static int TreeComparer(const void* left, const void* right)
 {
     const TCollatorMap* leftMap = left;
     const TCollatorMap* rightMap = right;
index 9c3b4c2..482a59a 100644 (file)
@@ -6,20 +6,7 @@
 #include "pal_locale.h"
 #include "pal_errors.h"
 
-typedef struct { int32_t key; UCollator* UCollator; } TCollatorMap;
-
-/*
- * For increased performance, we cache the UCollator objects for a locale and
- * share them across threads. This is safe (and supported in ICU) if we ensure
- * multiple threads are only ever dealing with const UCollators.
- */
-typedef struct
-{
-    UCollator* regular;
-    TCollatorMap* collatorsPerOption;
-    pthread_mutex_t collatorsLockObject;
-    void* pRoot;
-} SortHandle;
+typedef struct SortHandle SortHandle;
 
 DLLEXPORT ResultCode GlobalizationNative_GetSortHandle(const char* lpLocaleName, SortHandle** ppSortHandle);
 
index bed6166..55d9ca0 100644 (file)
@@ -21,7 +21,7 @@ typedef enum
 /*
 Converts a UErrorCode to a ResultCode.
 */
-DLLEXPORT static ResultCode GetResultCode(UErrorCode err)
+static ResultCode GetResultCode(UErrorCode err)
 {
     if (err == U_BUFFER_OVERFLOW_ERROR || err == U_STRING_NOT_TERMINATED_WARNING)
     {
index 84af3ba..5663c63 100644 (file)
@@ -417,13 +417,13 @@ int32_t GlobalizationNative_GetLocaleInfoInt(
 
     switch (localeNumberData)
     {
-        case LanguageId:
+        case LocaleNumber_LanguageId:
             *value = uloc_getLCID(locale);
             break;
-        case MeasurementSystem:
+        case LocaleNumber_MeasurementSystem:
             status = GetMeasurementSystem(locale, value);
             break;
-        case FractionalDigitsCount:
+        case LocaleNumber_FractionalDigitsCount:
         {
             UNumberFormat* numformat = unum_open(UNUM_DECIMAL, NULL, 0, locale, NULL, &status);
             if (U_SUCCESS(status))
@@ -433,10 +433,10 @@ int32_t GlobalizationNative_GetLocaleInfoInt(
             }
             break;
         }
-        case NegativeNumberFormat:
+        case LocaleNumber_NegativeNumberFormat:
             *value = GetNumberNegativePattern(locale);
             break;
-        case MonetaryFractionalDigitsCount:
+        case LocaleNumber_MonetaryFractionalDigitsCount:
         {
             UNumberFormat* numformat = unum_open(UNUM_CURRENCY, NULL, 0, locale, NULL, &status);
             if (U_SUCCESS(status))
@@ -446,13 +446,13 @@ int32_t GlobalizationNative_GetLocaleInfoInt(
             }
             break;
         }
-        case PositiveMonetaryNumberFormat:
+        case LocaleNumber_PositiveMonetaryNumberFormat:
             *value = GetCurrencyPositivePattern(locale);
             break;
-        case NegativeMonetaryNumberFormat:
+        case LocaleNumber_NegativeMonetaryNumberFormat:
             *value = GetCurrencyNegativePattern(locale);
             break;
-        case FirstWeekOfYear:
+        case LocaleNumber_FirstWeekOfYear:
         {
             // corresponds to DateTimeFormat.CalendarWeekRule
             UCalendar* pCal = ucal_open(NULL, 0, locale, UCAL_TRADITIONAL, &status);
@@ -463,15 +463,15 @@ int32_t GlobalizationNative_GetLocaleInfoInt(
                 int minDaysInWeek = ucal_getAttribute(pCal, UCAL_MINIMAL_DAYS_IN_FIRST_WEEK);
                 if (minDaysInWeek == 1)
                 {
-                    *value = FirstDay;
+                    *value = WeekRule_FirstDay;
                 }
                 else if (minDaysInWeek == 7)
                 {
-                    *value = FirstFullWeek;
+                    *value = WeekRule_FirstFullWeek;
                 }
                 else if (minDaysInWeek >= 4)
                 {
-                    *value = FirstFourDayWeek;
+                    *value = WeekRule_FirstFourDayWeek;
                 }
                 else
                 {
@@ -481,7 +481,7 @@ int32_t GlobalizationNative_GetLocaleInfoInt(
             ucal_close(pCal);
             break;
         }
-        case ReadingLayout:
+        case LocaleNumber_ReadingLayout:
         {
             // coresponds to values 0 and 1 in LOCALE_IREADINGLAYOUT (values 2 and 3 not
             // used in coreclr)
@@ -496,7 +496,7 @@ int32_t GlobalizationNative_GetLocaleInfoInt(
             }
             break;
         }
-        case FirstDayofWeek:
+        case LocaleNumber_FirstDayofWeek:
         {
             UCalendar* pCal = ucal_open(NULL, 0, locale, UCAL_TRADITIONAL, &status);
 
@@ -507,10 +507,10 @@ int32_t GlobalizationNative_GetLocaleInfoInt(
             ucal_close(pCal);
             break;
         }
-        case NegativePercentFormat:
+        case LocaleNumber_NegativePercentFormat:
             *value = GetPercentNegativePattern(locale);
             break;
-        case PositivePercentFormat:
+        case LocaleNumber_PositivePercentFormat:
             *value = GetPercentPositivePattern(locale);
             break;
         default:
@@ -544,10 +544,10 @@ int32_t GlobalizationNative_GetLocaleInfoGroupingSizes(
     UNumberFormatStyle style;
     switch (localeGroupingData)
     {
-        case Digit:
+        case LocaleNumber_Digit:
             style = UNUM_DECIMAL;
             break;
-        case Monetary:
+        case LocaleNumber_Monetary:
             style = UNUM_CURRENCY;
             break;
         default:
index 670c424..32eb3fd 100644 (file)
 // The numeric values of the enum members match their Win32 counterparts.
 typedef enum
 {
-    LanguageId = 0x01,
-    MeasurementSystem = 0x0D,
-    FractionalDigitsCount = 0x00000011,
-    NegativeNumberFormat = 0x00001010,
-    MonetaryFractionalDigitsCount = 0x00000019,
-    PositiveMonetaryNumberFormat = 0x0000001B,
-    NegativeMonetaryNumberFormat = 0x0000001C,
-    FirstDayofWeek = 0x0000100C,
-    FirstWeekOfYear = 0x0000100D,
-    ReadingLayout = 0x00000070,
-    NegativePercentFormat = 0x00000074,
-    PositivePercentFormat = 0x00000075,
-    Digit = 0x00000010,
-    Monetary = 0x00000018
+    LocaleNumber_LanguageId = 0x01,
+    LocaleNumber_MeasurementSystem = 0x0D,
+    LocaleNumber_FractionalDigitsCount = 0x00000011,
+    LocaleNumber_NegativeNumberFormat = 0x00001010,
+    LocaleNumber_MonetaryFractionalDigitsCount = 0x00000019,
+    LocaleNumber_PositiveMonetaryNumberFormat = 0x0000001B,
+    LocaleNumber_NegativeMonetaryNumberFormat = 0x0000001C,
+    LocaleNumber_FirstDayofWeek = 0x0000100C,
+    LocaleNumber_FirstWeekOfYear = 0x0000100D,
+    LocaleNumber_ReadingLayout = 0x00000070,
+    LocaleNumber_NegativePercentFormat = 0x00000074,
+    LocaleNumber_PositivePercentFormat = 0x00000075,
+    LocaleNumber_Digit = 0x00000010,
+    LocaleNumber_Monetary = 0x00000018
 } LocaleNumberData;
 
 // Enum that corresponds to managed enum System.Globalization.CalendarWeekRule
 typedef enum
 {
-    FirstDay = 0,
-    FirstFullWeek = 1,
-    FirstFourDayWeek = 2
+    WeekRule_FirstDay = 0,
+    WeekRule_FirstFullWeek = 1,
+    WeekRule_FirstFourDayWeek = 2
 } CalendarWeekRule;
 
 DLLEXPORT int32_t GlobalizationNative_GetLocaleInfoInt(const UChar* localeName,
index 97cc42a..a989b57 100644 (file)
@@ -219,39 +219,39 @@ int32_t GlobalizationNative_GetLocaleInfoString(const UChar* localeName,
 
     switch (localeStringData)
     {
-        case LocalizedDisplayName:
+        case LocaleString_LocalizedDisplayName:
             uloc_getDisplayName(locale, DetectDefaultLocaleName(), value, valueLength, &status);
             break;
-        case EnglishDisplayName:
+        case LocaleString_EnglishDisplayName:
             uloc_getDisplayName(locale, ULOC_ENGLISH, value, valueLength, &status);
             break;
-        case NativeDisplayName:
+        case LocaleString_NativeDisplayName:
             uloc_getDisplayName(locale, locale, value, valueLength, &status);
             break;
-        case LocalizedLanguageName:
+        case LocaleString_LocalizedLanguageName:
             uloc_getDisplayLanguage(locale, DetectDefaultLocaleName(), value, valueLength, &status);
             break;
-        case EnglishLanguageName:
+        case LocaleString_EnglishLanguageName:
             uloc_getDisplayLanguage(locale, ULOC_ENGLISH, value, valueLength, &status);
             break;
-        case NativeLanguageName:
+        case LocaleString_NativeLanguageName:
             uloc_getDisplayLanguage(locale, locale, value, valueLength, &status);
             break;
-        case EnglishCountryName:
+        case LocaleString_EnglishCountryName:
             uloc_getDisplayCountry(locale, ULOC_ENGLISH, value, valueLength, &status);
             break;
-        case NativeCountryName:
+        case LocaleString_NativeCountryName:
             uloc_getDisplayCountry(locale, locale, value, valueLength, &status);
             break;
-        case ListSeparator:
+        case LocaleString_ListSeparator:
         // fall through
-        case ThousandSeparator:
+        case LocaleString_ThousandSeparator:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_GROUPING_SEPARATOR_SYMBOL, value, valueLength);
             break;
-        case DecimalSeparator:
+        case LocaleString_DecimalSeparator:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_DECIMAL_SEPARATOR_SYMBOL, value, valueLength);
             break;
-        case Digits:
+        case LocaleString_Digits:
             status = GetDigitSymbol(locale, status, UNUM_ZERO_DIGIT_SYMBOL, 0, value, valueLength);
             // symbols UNUM_ONE_DIGIT to UNUM_NINE_DIGIT are contiguous
             for (int32_t symbol = UNUM_ONE_DIGIT_SYMBOL; symbol <= UNUM_NINE_DIGIT_SYMBOL; symbol++)
@@ -261,56 +261,56 @@ int32_t GlobalizationNative_GetLocaleInfoString(const UChar* localeName,
                     locale, status, (UNumberFormatSymbol)symbol, charIndex, value, valueLength);
             }
             break;
-        case MonetarySymbol:
+        case LocaleString_MonetarySymbol:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_CURRENCY_SYMBOL, value, valueLength);
             break;
-        case Iso4217MonetarySymbol:
+        case LocaleString_Iso4217MonetarySymbol:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_INTL_CURRENCY_SYMBOL, value, valueLength);
             break;
-        case CurrencyEnglishName:
+        case LocaleString_CurrencyEnglishName:
             status = GetLocaleCurrencyName(locale, FALSE, value, valueLength);
             break;
-        case CurrencyNativeName:
+        case LocaleString_CurrencyNativeName:
             status = GetLocaleCurrencyName(locale, TRUE, value, valueLength);
             break;
-        case MonetaryDecimalSeparator:
+        case LocaleString_MonetaryDecimalSeparator:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_MONETARY_SEPARATOR_SYMBOL, value, valueLength);
             break;
-        case MonetaryThousandSeparator:
+        case LocaleString_MonetaryThousandSeparator:
             status =
                 GetLocaleInfoDecimalFormatSymbol(locale, UNUM_MONETARY_GROUPING_SEPARATOR_SYMBOL, value, valueLength);
             break;
-        case AMDesignator:
+        case LocaleString_AMDesignator:
             status = GetLocaleInfoAmPm(locale, TRUE, value, valueLength);
             break;
-        case PMDesignator:
+        case LocaleString_PMDesignator:
             status = GetLocaleInfoAmPm(locale, FALSE, value, valueLength);
             break;
-        case PositiveSign:
+        case LocaleString_PositiveSign:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_PLUS_SIGN_SYMBOL, value, valueLength);
             break;
-        case NegativeSign:
+        case LocaleString_NegativeSign:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_MINUS_SIGN_SYMBOL, value, valueLength);
             break;
-        case Iso639LanguageTwoLetterName:
+        case LocaleString_Iso639LanguageTwoLetterName:
             status = GetLocaleIso639LanguageTwoLetterName(locale, value, valueLength);
             break;
-        case Iso639LanguageThreeLetterName:
+        case LocaleString_Iso639LanguageThreeLetterName:
             status = GetLocaleIso639LanguageThreeLetterName(locale, value, valueLength);
             break;
-        case Iso3166CountryName:
+        case LocaleString_Iso3166CountryName:
             status = GetLocaleIso3166CountryName(locale, value, valueLength);
             break;
-        case Iso3166CountryName2:
+        case LocaleString_Iso3166CountryName2:
             status = GetLocaleIso3166CountryCode(locale, value, valueLength);
             break;
-        case NaNSymbol:
+        case LocaleString_NaNSymbol:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_NAN_SYMBOL, value, valueLength);
             break;
-        case PositiveInfinitySymbol:
+        case LocaleString_PositiveInfinitySymbol:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_INFINITY_SYMBOL, value, valueLength);
             break;
-        case ParentName:
+        case LocaleString_ParentName:
         {
             // ICU supports lang[-script][-region][-variant] so up to 4 parents
             // including invariant locale
@@ -324,10 +324,10 @@ int32_t GlobalizationNative_GetLocaleInfoString(const UChar* localeName,
             }
             break;
         }
-        case PercentSymbol:
+        case LocaleString_PercentSymbol:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_PERCENT_SYMBOL, value, valueLength);
             break;
-        case PerMilleSymbol:
+        case LocaleString_PerMilleSymbol:
             status = GetLocaleInfoDecimalFormatSymbol(locale, UNUM_PERMILL_SYMBOL, value, valueLength);
             break;
         default:
index cb6a7b3..5889428 100644 (file)
 // The numeric values of the enum members match their Win32 counterparts.
 typedef enum
 {
-    LocalizedDisplayName = 0x02,
-    EnglishDisplayName = 0x00000072,
-    NativeDisplayName = 0x00000073,
-    LocalizedLanguageName = 0x0000006f,
-    EnglishLanguageName = 0x00001001,
-    NativeLanguageName = 0x04,
-    EnglishCountryName = 0x00001002,
-    NativeCountryName = 0x08,
-    ListSeparator = 0x0C,
-    DecimalSeparator = 0x0E,
-    ThousandSeparator = 0x0F,
-    Digits = 0x00000013,
-    MonetarySymbol = 0x00000014,
-    CurrencyEnglishName = 0x00001007,
-    CurrencyNativeName = 0x00001008,
-    Iso4217MonetarySymbol = 0x00000015,
-    MonetaryDecimalSeparator = 0x00000016,
-    MonetaryThousandSeparator = 0x00000017,
-    AMDesignator = 0x00000028,
-    PMDesignator = 0x00000029,
-    PositiveSign = 0x00000050,
-    NegativeSign = 0x00000051,
-    Iso639LanguageTwoLetterName = 0x00000059,
-    Iso639LanguageThreeLetterName = 0x00000067,
-    Iso3166CountryName = 0x0000005A,
-    Iso3166CountryName2= 0x00000068,
-    NaNSymbol = 0x00000069,
-    PositiveInfinitySymbol = 0x0000006a,
-    ParentName = 0x0000006d,
-    PercentSymbol = 0x00000076,
-    PerMilleSymbol = 0x00000077
+    LocaleString_LocalizedDisplayName = 0x02,
+    LocaleString_EnglishDisplayName = 0x00000072,
+    LocaleString_NativeDisplayName = 0x00000073,
+    LocaleString_LocalizedLanguageName = 0x0000006f,
+    LocaleString_EnglishLanguageName = 0x00001001,
+    LocaleString_NativeLanguageName = 0x04,
+    LocaleString_EnglishCountryName = 0x00001002,
+    LocaleString_NativeCountryName = 0x08,
+    LocaleString_ListSeparator = 0x0C,
+    LocaleString_DecimalSeparator = 0x0E,
+    LocaleString_ThousandSeparator = 0x0F,
+    LocaleString_Digits = 0x00000013,
+    LocaleString_MonetarySymbol = 0x00000014,
+    LocaleString_CurrencyEnglishName = 0x00001007,
+    LocaleString_CurrencyNativeName = 0x00001008,
+    LocaleString_Iso4217MonetarySymbol = 0x00000015,
+    LocaleString_MonetaryDecimalSeparator = 0x00000016,
+    LocaleString_MonetaryThousandSeparator = 0x00000017,
+    LocaleString_AMDesignator = 0x00000028,
+    LocaleString_PMDesignator = 0x00000029,
+    LocaleString_PositiveSign = 0x00000050,
+    LocaleString_NegativeSign = 0x00000051,
+    LocaleString_Iso639LanguageTwoLetterName = 0x00000059,
+    LocaleString_Iso639LanguageThreeLetterName = 0x00000067,
+    LocaleString_Iso3166CountryName = 0x0000005A,
+    LocaleString_Iso3166CountryName2= 0x00000068,
+    LocaleString_NaNSymbol = 0x00000069,
+    LocaleString_PositiveInfinitySymbol = 0x0000006a,
+    LocaleString_ParentName = 0x0000006d,
+    LocaleString_PercentSymbol = 0x00000076,
+    LocaleString_PerMilleSymbol = 0x00000077
 } LocaleStringData;
 
 DLLEXPORT int32_t GlobalizationNative_GetLocaleInfoString(const UChar* localeName,
index 7ed2a2c..bf2a9dc 100644 (file)
@@ -28,7 +28,12 @@ ResultCode GlobalizationNative_GetTimeZoneDisplayName(const UChar* localeName,
     // has no public option for this. For now, just use the ICU standard name for both Standard and Generic
     // (which is the same behavior on Windows with the mincore TIME_ZONE_INFORMATION APIs).
     ucal_getTimeZoneDisplayName(
-        calendar, type == DaylightSavings ? UCAL_DST : UCAL_STANDARD, locale, result, resultLength, &err);
+        calendar,
+        type == TimeZoneDisplayName_DaylightSavings ? UCAL_DST : UCAL_STANDARD,
+        locale,
+        result,
+        resultLength,
+        &err);
 
     ucal_close(calendar);
     return GetResultCode(err);
index bee24eb..1c030ca 100644 (file)
@@ -12,9 +12,9 @@ These values should be kept in sync with the managed Interop.GlobalizationIntero
 */
 typedef enum
 {
-    Generic = 0,
-    Standard = 1,
-    DaylightSavings = 2,
+    TimeZoneDisplayName_Generic = 0,
+    TimeZoneDisplayName_Standard = 1,
+    TimeZoneDisplayName_DaylightSavings = 2,
 } TimeZoneDisplayNameType;
 
 DLLEXPORT ResultCode GlobalizationNative_GetTimeZoneDisplayName(const UChar* localeName,