diff --git a/embed.fnc b/embed.fnc index da753ca1ad26..467ca6a5bc98 100644 --- a/embed.fnc +++ b/embed.fnc @@ -3728,11 +3728,11 @@ CRTip |unsigned int|variant_byte_number \ |PERL_UINTMAX_T word #endif #if defined(EMULATE_THREAD_SAFE_LOCALES) -Cp |void |category_lock_i|const unsigned int cat_index \ +Cp |void |category_lock_i|const locale_category_index cat_index \ |NN const char *file \ |const line_t caller_line Cp |void |category_unlock_i \ - |const unsigned int cat_index \ + |const locale_category_index cat_index \ |NN const char *file \ |const line_t caller_line Cip |int |posix_LC_foo_ |const int c \ @@ -4345,14 +4345,14 @@ S |const char *|calculate_LC_ALL_string \ |const calc_LC_ALL_format format \ |const bool return_in_setlocale_buf \ |const line_t caller_line -RS |unsigned int|get_category_index_helper \ +RS |locale_category_index|get_category_index_helper \ |const int category \ |NULLOK bool *success \ |const line_t caller_line Ri |const char *|mortalized_pv_copy \ |NULLOK const char * const pv S |const char *|native_querylocale_i \ - |const unsigned int cat_index + |const locale_category_index cat_index S |void |new_LC_ALL |NULLOK const char *unused \ |bool force void @@ -4369,7 +4369,7 @@ ST |const char *|save_to_buffer \ |NULLOK const char **buf \ |NULLOK Size_t *buf_size Sr |void |setlocale_failure_panic_via_i \ - |const unsigned int cat_index \ + |const locale_category_index cat_index \ |NULLOK const char *current \ |NN const char *failed \ |const line_t proxy_caller_line \ @@ -4390,14 +4390,14 @@ RS |char * |my_setlocale_debug_string_i \ # if defined(EMULATE_THREAD_SAFE_LOCALES) || \ ( defined(USE_POSIX_2008_LOCALE) && !defined(USE_QUERYLOCALE) ) S |void |update_PL_curlocales_i \ - |const unsigned int index \ + |const locale_category_index index \ |NN const char *new_locale \ |const line_t caller_line # endif # if defined(HAS_NL_LANGINFO) || defined(HAS_NL_LANGINFO_L) S |const char *|my_langinfo_i \ |const nl_item item \ - |const unsigned int cat_index \ + |const locale_category_index cat_index \ |NN const char *locale \ |NN const char **retbufp \ |NULLOK Size_t *retbuf_sizep \ @@ -4405,7 +4405,7 @@ S |const char *|my_langinfo_i \ # else S |const char *|my_langinfo_i \ |const int item \ - |const unsigned int cat_index \ + |const locale_category_index cat_index \ |NN const char *locale \ |NN const char **retbufp \ |NULLOK Size_t *retbuf_sizep \ @@ -4454,11 +4454,11 @@ S |const char *|get_LC_ALL_display # endif # if defined(USE_POSIX_2008_LOCALE) S |bool |bool_setlocale_2008_i \ - |const unsigned int index \ + |const locale_category_index index \ |NN const char *new_locale \ |const line_t caller_line S |const char *|querylocale_2008_i \ - |const unsigned int index \ + |const locale_category_index index \ |const line_t line S |locale_t|use_curlocale_scratch # elif !defined(EMULATE_THREAD_SAFE_LOCALES) && \ @@ -4487,7 +4487,7 @@ S |const char *|wrap_wsetlocale \ # if defined(WIN32) || \ ( defined(USE_POSIX_2008_LOCALE) && !defined(USE_QUERYLOCALE) ) S |const char *|find_locale_from_environment \ - |const unsigned int index + |const locale_category_index index # endif # endif /* defined(USE_LOCALE) */ # if defined(USE_LOCALE) || defined(DEBUGGING) diff --git a/locale.c b/locale.c index 8fd6a48d4dba..1c8ebee36633 100644 --- a/locale.c +++ b/locale.c @@ -301,7 +301,7 @@ S_positional_name_value_xlation(const char * locale, bool direction) result */ __LINE__); - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { Safefree(individ_locales[i]); } @@ -1060,10 +1060,12 @@ STATIC const int category_masks[] = { /* On platforms that use positional notation for expressing LC_ALL, this maps * the position of each category to our corresponding internal index for it. - * This is initialized at run time if needed */ + * This is initialized at run time if needed. LC_ALL_INDEX_ is not legal for + * an individual locale, hence marks the lements here as not actually + * initialized. */ STATIC -unsigned int -map_LC_ALL_position_to_index[LOCALE_CATEGORIES_COUNT_] = { PERL_UINT_MAX }; +locale_category_index +map_LC_ALL_position_to_index[LOCALE_CATEGORIES_COUNT_] = { LC_ALL_INDEX_ }; # endif #endif @@ -1129,7 +1131,7 @@ S_get_displayable_string(pTHX_ # define get_category_index(cat) get_category_index_helper(cat, NULL, \ __LINE__) -STATIC unsigned int +STATIC locale_category_index S_get_category_index_helper(pTHX_ const int category, bool * succeeded, const line_t caller_line) { @@ -1138,7 +1140,7 @@ S_get_category_index_helper(pTHX_ const int category, bool * succeeded, /* Given a category, return the equivalent internal index we generally use * instead, warn or panic if not found. */ - unsigned int i; + locale_category_index i; /* Each line expands like: * case LC_CTYPE: i = LC_CTYPE_INDEX_; break; @@ -1429,7 +1431,7 @@ S_parse_LC_ALL_string(pTHX_ const char * string, * will be C for each ignored category and "" for the others. Then the * caller can individually set each category, and get the right answer. */ if (single_component && ! isNAME_C_OR_POSIX(string)) { - for (unsigned int i = 0; i < LOCALE_CATEGORIES_COUNT_; i++) { + for (locale_category_index i = 0; i < LOCALE_CATEGORIES_COUNT_; i++) { OVERRIDE_AND_SAVEPV(string, strlen(string), output[i], i, override); } @@ -1576,7 +1578,7 @@ S_parse_LC_ALL_string(pTHX_ const char * string, # endif { /* Here is the name=value notation */ - for (unsigned int i = 0; i < LOCALE_CATEGORIES_COUNT_; i++) { + for (locale_category_index i = 0; i < LOCALE_CATEGORIES_COUNT_; i++) { if (! seen[i]) { error = incomplete; goto failure; @@ -1602,7 +1604,7 @@ S_parse_LC_ALL_string(pTHX_ const char * string, failure: /* Don't leave memory dangling that we allocated before the failure */ - for (unsigned int i = 0; i < LOCALE_CATEGORIES_COUNT_; i++) { + for (locale_category_index i = 0; i < LOCALE_CATEGORIES_COUNT_; i++) { if (seen[i]) { Safefree(output[i]); output[i] = NULL; @@ -2175,7 +2177,7 @@ S_less_dicey_bool_setlocale_r(pTHX_ const int cat, const char * locale) # define querylocale_r(cat) querylocale_i(get_category_index(cat)) STATIC const char * -S_querylocale_emulate_safe_i(pTHX_ const unsigned int cat_index, +S_querylocale_emulate_safe_i(pTHX_ const locale_category_index cat_index, const line_t caller_line) { assert(cat_index <= LOCALE_CATEGORIES_COUNT_ + 1); @@ -2292,7 +2294,7 @@ S_bool_setlocale_emulate_safe_r(pTHX_ * thread-safe implementations. */ void -Perl_category_lock_i(pTHX_ unsigned int cat_index, +Perl_category_lock_i(pTHX_ locale_category_index cat_index, const char * file, const line_t caller_line) { @@ -2395,7 +2397,7 @@ Perl_category_lock_i(pTHX_ unsigned int cat_index, } void -Perl_category_unlock_i(pTHX_ unsigned int cat_index, +Perl_category_unlock_i(pTHX_ locale_category_index cat_index, const char * file, const line_t caller_line) { @@ -2483,7 +2485,7 @@ Perl_category_unlock_i(pTHX_ unsigned int cat_index, # define querylocale_r(cat) querylocale_i(get_category_index(cat)) STATIC const char * -S_querylocale_2008_i(pTHX_ const unsigned int index, const line_t caller_line) +S_querylocale_2008_i(pTHX_ const locale_category_index index, const line_t caller_line) { PERL_ARGS_ASSERT_QUERYLOCALE_2008_I; assert(index <= LC_ALL_INDEX_); @@ -2647,7 +2649,7 @@ STATIC bool S_bool_setlocale_2008_i(pTHX_ /* Our internal index of the 'category' setlocale is called with */ - const unsigned int index, + const locale_category_index index, const char * new_locale, /* The locale to set the category to */ const line_t caller_line /* Called from this line number */ ) @@ -2927,7 +2929,7 @@ S_bool_setlocale_2008_i(pTHX_ /* Loop, using the previous iteration's result as the basis for the * next one. (The first time we effectively use the locale in * force upon entry to this function.) */ - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { new_obj = newlocale(category_masks[i], new_locales[i], basis_obj); @@ -2948,7 +2950,7 @@ S_bool_setlocale_2008_i(pTHX_ * failed */ freelocale(basis_obj); - for (unsigned int j = 0; j < LC_ALL_INDEX_; j++) { + for (locale_category_index j = 0; j < LC_ALL_INDEX_; j++) { Safefree(new_locales[j]); } @@ -2956,7 +2958,7 @@ S_bool_setlocale_2008_i(pTHX_ } /* Success for all categories. */ - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { update_PL_curlocales_i(i, new_locales[i], caller_line); Safefree(new_locales[i]); } @@ -3067,7 +3069,7 @@ S_bool_setlocale_2008_i(pTHX_ STATIC void S_update_PL_curlocales_i(pTHX_ - const unsigned int index, + const locale_category_index index, const char * new_locale, const line_t caller_line) { @@ -3109,7 +3111,7 @@ S_update_PL_curlocales_i(pTHX_ # ifdef LC_ALL else { /* LC_ALL */ - for (unsigned int i = 0; i <= LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i <= LC_ALL_INDEX_; i++) { Safefree(PL_curlocales[i]); PL_curlocales[i] = NULL; } @@ -3122,7 +3124,6 @@ S_update_PL_curlocales_i(pTHX_ it earlier had to have succeeded */ caller_line)) - { case invalid: case no_array: @@ -3314,7 +3315,7 @@ S_calculate_LC_ALL_string(pTHX_ const char ** category_locales_list, /* The total length then is just the sum of the above boiler-plate plus the * total strlen()s of the locale name of each individual category. */ - for (unsigned int i = 0; i < LOCALE_CATEGORIES_COUNT_; i++) { + for (locale_category_index i = 0; i < LOCALE_CATEGORIES_COUNT_; i++) { const char * entry = ENTRY(i, locales_list, format); total_len += strlen(entry); @@ -3439,7 +3440,7 @@ S_calculate_LC_ALL_string(pTHX_ const char ** category_locales_list, && ! defined(USE_QUERYLOCALE)) STATIC const char * -S_find_locale_from_environment(pTHX_ const unsigned int index) +S_find_locale_from_environment(pTHX_ const locale_category_index index) { /* NB: This function may actually change the locale on Windows. It * currently is designed to be called only from setting the locale on @@ -3546,7 +3547,7 @@ S_find_locale_from_environment(pTHX_ const unsigned int index) * them all. If only an individual category is desired, to avoid * duplicating logic, we use the same loop, but set up the limits so it is * only executed once, for that particular category. */ - unsigned int lower, upper, offset; + locale_category_index lower, upper, offset; if (index == LC_ALL_INDEX_) { lower = 0; upper = LC_ALL_INDEX_ - 1; @@ -3645,7 +3646,7 @@ S_get_LC_ALL_display(pTHX) STATIC void S_setlocale_failure_panic_via_i(pTHX_ - const unsigned int cat_index, + const locale_category_index cat_index, const char * current, const char * failed, const line_t proxy_caller_line, @@ -4384,7 +4385,7 @@ S_new_LC_ALL(pTHX_ const char *unused, bool force) /* LC_ALL updates all the things we care about. */ - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { if (update_functions[i]) { const char * this_locale = querylocale_i(i); update_functions[i](aTHX_ this_locale, force); @@ -4590,7 +4591,7 @@ S_win32_setlocale(pTHX_ int category, const char* locale) #ifdef USE_LOCALE STATIC const char * -S_native_querylocale_i(pTHX_ const unsigned int cat_index) +S_native_querylocale_i(pTHX_ const locale_category_index cat_index) { /* Determine the current locale and return it in the form the platform's * native locale handling understands. This is different only from our @@ -4716,9 +4717,9 @@ Perl_setlocale(const int category, const char * locale) category, locale)); bool valid_category; - unsigned int cat_index = get_category_index_helper(category, - &valid_category, - __LINE__); + locale_category_index cat_index = get_category_index_helper(category, + &valid_category, + __LINE__); if (! valid_category) { if (ckWARN(WARN_LOCALE)) { const char * conditional_warn_text; @@ -5260,22 +5261,22 @@ S_my_localeconv(pTHX_ const int item) * If not paying attention to that either, the code below should end up not * using this. Make sure that things blow up if that avoidance gets lost, * by setting the category to -1 */ - unsigned int numeric_index; - unsigned int monetary_index; + locale_category_index numeric_index; + locale_category_index monetary_index; # ifdef USE_LOCALE_NUMERIC numeric_index = LC_NUMERIC_INDEX_; # elif defined(USE_LOCALE_CTYPE) numeric_index = LC_CTYPE_INDEX_; # else - numeric_index = (unsigned) -1; + numeric_index = LC_ALL_INDEX_; /* Out-of-bounds */ # endif # ifdef USE_LOCALE_MONETARY monetary_index = LC_MONETARY_INDEX_; # elif defined(USE_LOCALE_CTYPE) monetary_index = LC_CTYPE_INDEX_; # else - monetary_index = (unsigned) -1; + monetary_index = LC_ALL_INDEX_; /* Out-of-bounds */ # endif /* Some platforms, for correct non-mojibake results, require LC_CTYPE's @@ -6189,7 +6190,7 @@ Perl_langinfo8(const nl_item item, utf8ness_t * utf8ness) STATIC const char * S_my_langinfo_i(pTHX_ const nl_item item, /* The item to look up */ - const unsigned int cat_index, /* The locale category that + const locale_category_index cat_index, /* The locale category that controls it */ /* The locale to look up 'item' in. */ const char * locale, @@ -7112,7 +7113,7 @@ S_give_perl_locale_control(pTHX_ # else - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { void_setlocale_i_with_caller(i, locales[i], __FILE__, caller_line); } @@ -7153,7 +7154,7 @@ S_output_check_environment_warning(pTHX_ const char * const language, lc_all ? lc_all : "unset", lc_all ? '"' : ')'); - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { const char * value = PerlEnv_getenv(category_names[i]); PerlIO_printf(Perl_error_log, "\t%s = %c%s%c,\n", @@ -7508,7 +7509,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) # endif # endif - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { assert(category_name_lengths[i] == strlen(category_names[i])); } @@ -7526,7 +7527,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) wcrtomb(NULL, L'\0', &PL_wcrtomb_ps); # endif # ifdef EMULATE_THREAD_SAFE_LOCALES - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { PL_restore_locale[i] = NULL; } # endif @@ -7536,7 +7537,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) /* If we haven't done so already, translate the LC_ALL positions of * categories into our internal indices. */ - if (map_LC_ALL_position_to_index[0] == PERL_UINT_MAX) { + if (map_LC_ALL_position_to_index[0] == LC_ALL_INDEX_) { /* Use this array initialized by a config.h constant */ int lc_all_category_positions[] = LC_ALL_CATEGORY_POSITIONS_INIT; @@ -7615,7 +7616,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) # endif # ifdef USE_PL_CURLOCALES - for (unsigned int i = 0; i <= LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i <= LC_ALL_INDEX_; i++) { PL_curlocales[i] = savepv("C"); } @@ -7764,7 +7765,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) bool setlocale_failure = FALSE; /* This trial hasn't failed so far */ bool dowarn = trial == 0 && locwarn; - for (unsigned int j = 0; j < LC_ALL_INDEX_; j++) { + for (locale_category_index j = 0; j < LC_ALL_INDEX_; j++) { STDIZED_SETLOCALE_LOCK; curlocales[j] = savepv(stdized_setlocale(categories[j], locale)); STDIZED_SETLOCALE_UNLOCK; @@ -7793,7 +7794,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) PerlIO_printf(Perl_error_log, "perl: warning: Setting locale failed for the categories:\n"); - for (unsigned int j = 0; j < LC_ALL_INDEX_; j++) { + for (locale_category_index j = 0; j < LC_ALL_INDEX_; j++) { if (! curlocales[j]) { PerlIO_printf(Perl_error_log, "\t%s\n", category_names[j]); } @@ -7866,7 +7867,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) const char * system_locales[LC_ALL_INDEX_] = { NULL }; - for (unsigned int j = 0; j < LC_ALL_INDEX_; j++) { + for (locale_category_index j = 0; j < LC_ALL_INDEX_; j++) { STDIZED_SETLOCALE_LOCK; system_locales[j] = savepv(stdized_setlocale(categories[j], NULL)); @@ -7886,7 +7887,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) __LINE__); description = "what the system says"; - for (unsigned int j = 0; j < LC_ALL_INDEX_; j++) { + for (locale_category_index j = 0; j < LC_ALL_INDEX_; j++) { Safefree(system_locales[j]); } # endif @@ -7911,7 +7912,7 @@ Perl_init_i18nl10n(pTHX_ int printwarn) give_perl_locale_control((const char **) &curlocales, __LINE__); - for (unsigned int j = 0; j < LC_ALL_INDEX_; j++) { + for (locale_category_index j = 0; j < LC_ALL_INDEX_; j++) { Safefree(curlocales[j]); } @@ -8825,7 +8826,7 @@ S_toggle_locale_i(pTHX_ const unsigned cat_index, } STATIC void -S_restore_toggled_locale_i(pTHX_ const unsigned int cat_index, +S_restore_toggled_locale_i(pTHX_ const locale_category_index cat_index, const char * restore_locale, const line_t caller_line) { @@ -9329,7 +9330,7 @@ Perl_switch_to_global_locale(pTHX) /* Set the global to what was our per-thread state */ POSIX_SETLOCALE_LOCK; - for (unsigned int i = 0; i < LC_ALL_INDEX_; i++) { + for (locale_category_index i = 0; i < LC_ALL_INDEX_; i++) { posix_setlocale(categories[i], cur_thread_locales[i]); } POSIX_SETLOCALE_UNLOCK; diff --git a/proto.h b/proto.h index 70c3980f5a72..3e7cee8de56f 100644 --- a/proto.h +++ b/proto.h @@ -5394,12 +5394,12 @@ Perl_variant_byte_number(PERL_UINTMAX_T word) #endif #if defined(EMULATE_THREAD_SAFE_LOCALES) PERL_CALLCONV void -Perl_category_lock_i(pTHX_ const unsigned int cat_index, const char *file, const line_t caller_line); +Perl_category_lock_i(pTHX_ const locale_category_index cat_index, const char *file, const line_t caller_line); # define PERL_ARGS_ASSERT_CATEGORY_LOCK_I \ assert(file) PERL_CALLCONV void -Perl_category_unlock_i(pTHX_ const unsigned int cat_index, const char *file, const line_t caller_line); +Perl_category_unlock_i(pTHX_ const locale_category_index cat_index, const char *file, const line_t caller_line); # define PERL_ARGS_ASSERT_CATEGORY_UNLOCK_I \ assert(file) @@ -6980,13 +6980,13 @@ STATIC const char * S_calculate_LC_ALL_string(pTHX_ const char **category_locales_list, const calc_LC_ALL_format format, const bool return_in_setlocale_buf, const line_t caller_line); # define PERL_ARGS_ASSERT_CALCULATE_LC_ALL_STRING -STATIC unsigned int +STATIC locale_category_index S_get_category_index_helper(pTHX_ const int category, bool *success, const line_t caller_line) __attribute__warn_unused_result__; # define PERL_ARGS_ASSERT_GET_CATEGORY_INDEX_HELPER STATIC const char * -S_native_querylocale_i(pTHX_ const unsigned int cat_index); +S_native_querylocale_i(pTHX_ const locale_category_index cat_index); # define PERL_ARGS_ASSERT_NATIVE_QUERYLOCALE_I STATIC void @@ -7006,7 +7006,7 @@ S_save_to_buffer(const char *string, const char **buf, Size_t *buf_size); # define PERL_ARGS_ASSERT_SAVE_TO_BUFFER PERL_STATIC_NO_RET void -S_setlocale_failure_panic_via_i(pTHX_ const unsigned int cat_index, const char *current, const char *failed, const line_t proxy_caller_line, const line_t immediate_caller_line, const char *higher_caller_file, const line_t higher_caller_line) +S_setlocale_failure_panic_via_i(pTHX_ const locale_category_index cat_index, const char *current, const char *failed, const line_t proxy_caller_line, const line_t immediate_caller_line, const char *higher_caller_file, const line_t higher_caller_line) __attribute__noreturn__; # define PERL_ARGS_ASSERT_SETLOCALE_FAILURE_PANIC_VIA_I \ assert(failed); assert(higher_caller_file) @@ -7026,20 +7026,20 @@ S_my_setlocale_debug_string_i(pTHX_ const unsigned cat_index, const char *locale # if defined(EMULATE_THREAD_SAFE_LOCALES) || \ ( defined(USE_POSIX_2008_LOCALE) && !defined(USE_QUERYLOCALE) ) STATIC void -S_update_PL_curlocales_i(pTHX_ const unsigned int index, const char *new_locale, const line_t caller_line); +S_update_PL_curlocales_i(pTHX_ const locale_category_index index, const char *new_locale, const line_t caller_line); # define PERL_ARGS_ASSERT_UPDATE_PL_CURLOCALES_I \ assert(new_locale) # endif # if defined(HAS_NL_LANGINFO) || defined(HAS_NL_LANGINFO_L) STATIC const char * -S_my_langinfo_i(pTHX_ const nl_item item, const unsigned int cat_index, const char *locale, const char **retbufp, Size_t *retbuf_sizep, utf8ness_t *utf8ness); +S_my_langinfo_i(pTHX_ const nl_item item, const locale_category_index cat_index, const char *locale, const char **retbufp, Size_t *retbuf_sizep, utf8ness_t *utf8ness); # define PERL_ARGS_ASSERT_MY_LANGINFO_I \ assert(locale); assert(retbufp) # else STATIC const char * -S_my_langinfo_i(pTHX_ const int item, const unsigned int cat_index, const char *locale, const char **retbufp, Size_t *retbuf_sizep, utf8ness_t *utf8ness); +S_my_langinfo_i(pTHX_ const int item, const locale_category_index cat_index, const char *locale, const char **retbufp, Size_t *retbuf_sizep, utf8ness_t *utf8ness); # define PERL_ARGS_ASSERT_MY_LANGINFO_I \ assert(locale); assert(retbufp) @@ -7110,12 +7110,12 @@ S_get_LC_ALL_display(pTHX); # endif # if defined(USE_POSIX_2008_LOCALE) STATIC bool -S_bool_setlocale_2008_i(pTHX_ const unsigned int index, const char *new_locale, const line_t caller_line); +S_bool_setlocale_2008_i(pTHX_ const locale_category_index index, const char *new_locale, const line_t caller_line); # define PERL_ARGS_ASSERT_BOOL_SETLOCALE_2008_I \ assert(new_locale) STATIC const char * -S_querylocale_2008_i(pTHX_ const unsigned int index, const line_t line); +S_querylocale_2008_i(pTHX_ const locale_category_index index, const line_t line); # define PERL_ARGS_ASSERT_QUERYLOCALE_2008_I STATIC locale_t @@ -7160,7 +7160,7 @@ S_wrap_wsetlocale(pTHX_ const int category, const char *locale); # if defined(WIN32) || \ ( defined(USE_POSIX_2008_LOCALE) && !defined(USE_QUERYLOCALE) ) STATIC const char * -S_find_locale_from_environment(pTHX_ const unsigned int index); +S_find_locale_from_environment(pTHX_ const locale_category_index index); # define PERL_ARGS_ASSERT_FIND_LOCALE_FROM_ENVIRONMENT # endif