Skip to content

Commit

Permalink
final
Browse files Browse the repository at this point in the history
  • Loading branch information
khwilliamson committed Feb 7, 2024
1 parent c8dccac commit 2127217
Showing 1 changed file with 15 additions and 4 deletions.
19 changes: 15 additions & 4 deletions locale.c
Original file line number Diff line number Diff line change
@@ -1,7 +1,14 @@
/* locale.c
./t/run/locale.t:my @locales = find_locales( [ 'LC_ALL', 'LC_CTYPE', 'LC_NUMERIC' ]);
./ext/I18N-Langinfo/t/Langinfo.t: my @locales = find_locales( [ qw(LC_TIME LC_CTYPE LC_MONETARY) ] );
./lib/locale.t:my @Locale = find_locales($categories);
./lib/locale.t:my @include_incompatible_locales = find_locales($categories,
*
123456789112345678921234567893123456789412345678951234567896123456789712345678981
* strptime
* what deltas for stdize changes?
* a bunch of copies aren't needed on nonthreaded
*
* Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
* 2002, 2003, 2005, 2006, 2007, 2008 by Larry Wall and others
*
Expand Down Expand Up @@ -268,14 +275,14 @@
* -Accflags=-DNO_POSIX_2008_LOCALE
* Even if the libc locale operations specified by the Posix 2008
* Standard are available on this platform and would otherwise be used
* (because this is a perl with multiplicity), perl is compiled to not
* (because this is a perl with XXX multiplicity), perl is compiled to not
* use them. This could be useful on platforms where the libc is
* buggy. This is like NO_THREAD_SAFE_LOCALE, but has no effect on
* platforms that don't have these functions.
*
* -Accflags=-DUSE_POSIX_2008_LOCALE
* Normally, setlocale() is used for locale operations on perls
* compiled without multiplicity. This option causes the locale
* compiled without XXX multiplicity. This option causes the locale
* operations defined by the Posix 2008 Standard to always be used
* instead. This could be useful on platforms where the libc
* setlocale() is buggy.
Expand Down Expand Up @@ -4133,7 +4140,7 @@ S_new_numeric(pTHX_ const char *newnum, bool force)
* */
PL_numeric_underlying = TRUE;
PL_numeric_standard = false;
PL_numeric_underlying_is_standard = true; /* Illegal combination */
PL_numeric_underlying_is_standard = true; /* WHY Illegal combination */

/* Passing a non-NULL causes the function call just below to
automatically set the UTF-8 flag on PL_underlying_radix_sv */
Expand Down Expand Up @@ -4213,6 +4220,7 @@ Perl_set_numeric_standard(pTHX_ const char * const file, const line_t line)
DEBUG_L(PerlIO_printf(Perl_debug_log, "Setting LC_NUMERIC locale to"
" standard C; called from %s: %"
LINE_Tf "\n", file, line));
/* XXX Maybe not in init? assert(PL_locale_mutex_depth > 0);*/

void_setlocale_c_with_caller(LC_NUMERIC, "C", file, line);
PL_numeric_standard = TRUE;
Expand Down Expand Up @@ -4245,7 +4253,7 @@ Perl_set_numeric_underlying(pTHX_ const char * const file, const line_t line)
DEBUG_L(PerlIO_printf(Perl_debug_log, "Setting LC_NUMERIC locale to %s;"
" called from %s: %" LINE_Tf "\n",
PL_numeric_name, file, line));
/* Maybe not in init? assert(PL_locale_mutex_depth > 0);*/
/* XXX Maybe not in init? assert(PL_locale_mutex_depth > 0);*/

void_setlocale_c_with_caller(LC_NUMERIC, PL_numeric_name, file, line);
PL_numeric_underlying = TRUE;
Expand Down Expand Up @@ -4949,6 +4957,9 @@ S_win32_setlocale(pTHX_ int category, const char* locale)

Safefree(PL_cur_LC_ALL);
PL_cur_LC_ALL = result;

DEBUG_L(PerlIO_printf(Perl_debug_log, "new PL_cur_LC_ALL=%s\n",
PL_cur_LC_ALL));
}

DEBUG_L(PerlIO_printf(Perl_debug_log, "new PL_cur_LC_ALL=%s\n",
Expand Down

0 comments on commit 2127217

Please sign in to comment.