summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2021-03-04 18:06:19 -0700
committerKarl Williamson <khw@cpan.org>2021-03-10 21:31:24 -0700
commit65c2a5af6c956eb2e6308d678d570dd4c5d8c2d8 (patch)
treefc33761bf020e8c4fe3f7ae661230fcb64e66b42
parent6e68a407e03ff00b86588138a3424d60ac47559a (diff)
downloadperl-65c2a5af6c956eb2e6308d678d570dd4c5d8c2d8.tar.gz
perl.h: Clarify debugging msg for locales
I wrote this years ago, and now have discovered it was written assuming the consumer is more familiar with the underlying code than warranted.
-rw-r--r--perl.h13
1 files changed, 9 insertions, 4 deletions
diff --git a/perl.h b/perl.h
index a28371267a..3235ee1254 100644
--- a/perl.h
+++ b/perl.h
@@ -6972,8 +6972,8 @@ cannot have changed since the precalculation.
# define LOCK_LC_NUMERIC_STANDARD() \
STMT_START { \
DEBUG_Lv(PerlIO_printf(Perl_debug_log, \
- "%s: %d: lock lc_numeric_standard: new depth=%d\n", \
- __FILE__, __LINE__, PL_numeric_standard + 1)); \
+ "%s: %d: lc_numeric_standard now locked to depth %d\n", \
+ __FILE__, __LINE__, PL_numeric_standard)); \
__ASSERT_(PL_numeric_standard) \
PL_numeric_standard++; \
} STMT_END
@@ -6987,8 +6987,13 @@ cannot have changed since the precalculation.
assert(0); \
} \
DEBUG_Lv(PerlIO_printf(Perl_debug_log, \
- "%s: %d: lc_numeric_standard decrement lock, new depth=%d\n", \
- __FILE__, __LINE__, PL_numeric_standard)); \
+ "%s: %d: ", __FILE__, __LINE__); \
+ if (PL_numeric_standard <= 1) \
+ PerlIO_printf(Perl_debug_log, \
+ "lc_numeric_standard now unlocked\n");\
+ else PerlIO_printf(Perl_debug_log, \
+ "lc_numeric_standard lock decremented to depth %d\n", \
+ PL_numeric_standard););\
} STMT_END
# define WITH_LC_NUMERIC_SET_TO_NEEDED_IN(in_lc_numeric, block) \