Skip to content

Commit

Permalink
l
Browse files Browse the repository at this point in the history
  • Loading branch information
khwilliamson committed Jan 27, 2023
1 parent 1793930 commit dc76640
Show file tree
Hide file tree
Showing 10 changed files with 856 additions and 634 deletions.
37 changes: 10 additions & 27 deletions embed.fnc
Expand Up @@ -4264,6 +4264,13 @@ S |void |populate_hash_from_localeconv \
|NN const lconv_offset_t *strings[2] \
|NULLOK const lconv_offset_t *integers
# endif /* defined(HAS_LOCALECONV) */
# if defined(LC_ALL) || defined(USE_POSIX_2008_LOCALE) || defined(DEBUGGING)
S |const char *|get_displayable_string \
|NN const char * const s \
|NN const char * const e \
|const bool is_utf8
# endif /* defined(LC_ALL) || defined(USE_POSIX_2008_LOCALE) || \
defined(DEBUGGING) */
# if defined(USE_LOCALE)
iR |const char *|mortalized_pv_copy \
|NULLOK const char * const pv
Expand Down Expand Up @@ -4324,6 +4331,9 @@ S |const char *|my_langinfo_i \
# endif /* !( defined(HAS_NL_LANGINFO) || defined(HAS_NL_LANGINFO_L) ) */
# if defined(LC_ALL)
S |const char *|native_query_LC_ALL
S |const char *|setlocale_from_aggregate_LC_ALL \
|NN const char *locale \
|const line_t line
# endif /* defined(LC_ALL) */
# if defined(USE_LOCALE_COLLATE)
S |void |new_collate |NN const char *newcoll \
Expand Down Expand Up @@ -4365,12 +4375,7 @@ S |const char *|emulate_setlocale_i \
S |const char *|my_querylocale_i \
|const unsigned int index
S |locale_t|use_curlocale_scratch
S |const char *|setlocale_from_aggregate_LC_ALL \
|NN const char *locale \
|const line_t line
# if defined(USE_QUERYLOCALE)
S |const char *|calculate_LC_ALL \
|const locale_t cur_obj
S |const char *|querylocale_l \
|const unsigned int index \
|const locale_t locale_obj
Expand All @@ -4381,29 +4386,13 @@ S |const char *|querylocale_l \
S |const char *|less_dicey_setlocale_r \
|const int category \
|NULLOK const char *locale
: Not currently used
S |void |less_dicey_void_setlocale_i \
|const unsigned cat_index \
|NN const char *locale \
|const line_t line
# if 0
S |bool |less_dicey_bool_setlocale_r \
|const int cat \
|NN const char *locale
# endif /* 0 */
# endif /* ( defined(USE_LOCALE_THREADS) && \
!defined(USE_THREAD_SAFE_LOCALE) && \
!defined(USE_THREAD_SAFE_LOCALE_EMULATION) ) && \
!defined(USE_POSIX_2008_LOCALE) */
# if !( defined(USE_POSIX_2008_LOCALE) && defined(USE_QUERYLOCALE) )
: regen/embed.pl can't currently cope with 'elif'
# if !defined(LC_ALL) || defined(USE_POSIX_2008_LOCALE) || \
defined(USE_THREAD_SAFE_LOCALE_EMULATION) || defined(WIN32)
S |const char *|calculate_LC_ALL \
|NN const char **individ_locales
# endif /* !defined(LC_ALL) || defined(USE_POSIX_2008_LOCALE) || \
defined(USE_THREAD_SAFE_LOCALE_EMULATION) || defined(WIN32) */
# endif /* !( defined(USE_POSIX_2008_LOCALE) && defined(USE_QUERYLOCALE) ) */
# if ( defined(USE_POSIX_2008_LOCALE) && !defined(USE_QUERYLOCALE) ) || \
defined(WIN32)
S |const char *|find_locale_from_environment \
Expand All @@ -4425,12 +4414,6 @@ S |const char *|wrap_wsetlocale \
|NULLOK const char *locale
# endif /* defined(WIN32) */
# endif /* defined(USE_LOCALE) */
# if defined(USE_POSIX_2008_LOCALE) || defined(DEBUGGING)
S |const char *|get_displayable_string \
|NN const char * const s \
|NN const char * const e \
|const bool is_utf8
# endif /* defined(USE_POSIX_2008_LOCALE) || defined(DEBUGGING) */
#endif /* defined(PERL_IN_LOCALE_C) */
#if defined(PERL_IN_MALLOC_C)
ST |int |adjust_size_and_find_bucket \
Expand Down
24 changes: 7 additions & 17 deletions embed.h
Expand Up @@ -1261,6 +1261,11 @@
# define my_localeconv(a) S_my_localeconv(aTHX_ a)
# define populate_hash_from_localeconv(a,b,c,d,e) S_populate_hash_from_localeconv(aTHX_ a,b,c,d,e)
# endif /* defined(HAS_LOCALECONV) */
# if defined(LC_ALL) || defined(USE_POSIX_2008_LOCALE) || \
defined(DEBUGGING)
# define get_displayable_string(a,b,c) S_get_displayable_string(aTHX_ a,b,c)
# endif /* defined(LC_ALL) || defined(USE_POSIX_2008_LOCALE) || \
defined(DEBUGGING) */
# if defined(USE_LOCALE)
# define get_category_index S_get_category_index
# define get_category_index_nowarn S_get_category_index_nowarn
Expand All @@ -1279,15 +1284,8 @@
# endif /* !( defined(HAS_NL_LANGINFO) || defined(HAS_NL_LANGINFO_L) ) */
# if defined(LC_ALL)
# define native_query_LC_ALL() S_native_query_LC_ALL(aTHX)
# define setlocale_from_aggregate_LC_ALL(a,b) S_setlocale_from_aggregate_LC_ALL(aTHX_ a,b)
# endif /* defined(LC_ALL) */
# if ( !defined(LC_ALL) || defined(USE_POSIX_2008_LOCALE) || \
defined(USE_THREAD_SAFE_LOCALE_EMULATION) || defined(WIN32) ) && \
!( defined(USE_POSIX_2008_LOCALE) && defined(USE_QUERYLOCALE) )
# define calculate_LC_ALL(a) S_calculate_LC_ALL(aTHX_ a)
# endif /* ( !defined(LC_ALL) || defined(USE_POSIX_2008_LOCALE) || \
defined(USE_THREAD_SAFE_LOCALE_EMULATION) || defined(WIN32) \
) && !( defined(USE_POSIX_2008_LOCALE) && \
defined(USE_QUERYLOCALE) ) */
# if defined(USE_LOCALE_COLLATE)
# define new_collate(a,b) S_new_collate(aTHX_ a,b)
# if defined(DEBUGGING)
Expand All @@ -1311,20 +1309,15 @@
# if defined(USE_POSIX_2008_LOCALE)
# define emulate_setlocale_i(a,b,c,d) S_emulate_setlocale_i(aTHX_ a,b,c,d)
# define my_querylocale_i(a) S_my_querylocale_i(aTHX_ a)
# define setlocale_from_aggregate_LC_ALL(a,b) S_setlocale_from_aggregate_LC_ALL(aTHX_ a,b)
# define use_curlocale_scratch() S_use_curlocale_scratch(aTHX)
# if defined(USE_QUERYLOCALE)
# define calculate_LC_ALL(a) S_calculate_LC_ALL(aTHX_ a)
# define querylocale_l(a,b) S_querylocale_l(aTHX_ a,b)
# endif /* defined(USE_QUERYLOCALE) */
# elif defined(USE_LOCALE_THREADS) && !defined(USE_THREAD_SAFE_LOCALE) \
&& !defined(USE_THREAD_SAFE_LOCALE_EMULATION) /* && \
!defined(USE_POSIX_2008_LOCALE) */
# define less_dicey_bool_setlocale_r(a,b) S_less_dicey_bool_setlocale_r(aTHX_ a,b)
# define less_dicey_setlocale_r(a,b) S_less_dicey_setlocale_r(aTHX_ a,b)
# define less_dicey_void_setlocale_i(a,b,c) S_less_dicey_void_setlocale_i(aTHX_ a,b,c)
# if 0
# define less_dicey_bool_setlocale_r(a,b) S_less_dicey_bool_setlocale_r(aTHX_ a,b)
# endif /* 0 */
# endif /* ( defined(USE_LOCALE_THREADS) && \
!defined(USE_THREAD_SAFE_LOCALE) && \
!defined(USE_THREAD_SAFE_LOCALE_EMULATION) ) && \
Expand All @@ -1341,9 +1334,6 @@
# define wrap_wsetlocale(a,b) S_wrap_wsetlocale(aTHX_ a,b)
# endif /* defined(WIN32) */
# endif /* defined(USE_LOCALE) */
# if defined(USE_POSIX_2008_LOCALE) || defined(DEBUGGING)
# define get_displayable_string(a,b,c) S_get_displayable_string(aTHX_ a,b,c)
# endif /* defined(USE_POSIX_2008_LOCALE) || defined(DEBUGGING) */
# endif /* defined(PERL_IN_LOCALE_C) */
# if defined(PERL_IN_MALLOC_C)
# define adjust_size_and_find_bucket S_adjust_size_and_find_bucket
Expand Down
2 changes: 1 addition & 1 deletion intrpvar.h
Expand Up @@ -746,7 +746,7 @@ PERLVARI(I, cur_locale_obj, locale_t, NULL)
#endif
#ifdef USE_PL_CURLOCALES

PERLVARA(I, curlocales, PERL_LOCALE_CATEGORIES_ALL_COUNT_, const char *)
PERLVARA(I, curlocales, PERL_LOCALE_CATEGORIES_PLUS_LC_ALL_COUNT_, const char *)

#endif
#ifdef USE_PL_CUR_LC_ALL
Expand Down

0 comments on commit dc76640

Please sign in to comment.