From 7bb8f702f9ddfc65ea019531908a111e0d4d8351 Mon Sep 17 00:00:00 2001 From: Karl Williamson Date: Wed, 18 Apr 2018 10:01:34 -0600 Subject: [PATCH] locale.c: Reorder some debugging statements I found these confusing trying to debug a field problem. This reorders them, adjusting the wording slightly to compensate --- locale.c | 26 ++++++++++++++------------ 1 file changed, 14 insertions(+), 12 deletions(-) diff --git a/locale.c b/locale.c index 67a2997..7653340 100644 --- a/locale.c +++ b/locale.c @@ -1423,19 +1423,20 @@ Perl_set_numeric_standard(pTHX) * to our records (which could be wrong if some XS code has changed the * locale behind our back) */ - do_setlocale_c(LC_NUMERIC, "C"); - PL_numeric_standard = TRUE; - PL_numeric_underlying = PL_numeric_underlying_is_standard; - set_numeric_radix(0); - # ifdef DEBUGGING if (DEBUG_L_TEST || debug_initialization) { PerlIO_printf(Perl_debug_log, - "LC_NUMERIC locale now is standard C\n"); + "Setting LC_NUMERIC locale to standard C\n"); } # endif + + do_setlocale_c(LC_NUMERIC, "C"); + PL_numeric_standard = TRUE; + PL_numeric_underlying = PL_numeric_underlying_is_standard; + set_numeric_radix(0); + #endif /* USE_LOCALE_NUMERIC */ } @@ -1452,20 +1453,21 @@ Perl_set_numeric_underlying(pTHX) * if toggling isn't necessary according to our records (which could be * wrong if some XS code has changed the locale behind our back) */ - do_setlocale_c(LC_NUMERIC, PL_numeric_name); - PL_numeric_standard = PL_numeric_underlying_is_standard; - PL_numeric_underlying = TRUE; - set_numeric_radix(! PL_numeric_standard); - # ifdef DEBUGGING if (DEBUG_L_TEST || debug_initialization) { PerlIO_printf(Perl_debug_log, - "LC_NUMERIC locale now is %s\n", + "Setting LC_NUMERIC locale to %s\n", PL_numeric_name); } # endif + + do_setlocale_c(LC_NUMERIC, PL_numeric_name); + PL_numeric_standard = PL_numeric_underlying_is_standard; + PL_numeric_underlying = TRUE; + set_numeric_radix(! PL_numeric_standard); + #endif /* USE_LOCALE_NUMERIC */ } -- 1.8.3.1