summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--locale.c3
-rw-r--r--pod/perldiag.pod6
-rw-r--r--t/porting/diag.t1
3 files changed, 8 insertions, 2 deletions
diff --git a/locale.c b/locale.c
index 163f412ed1..5893212e86 100644
--- a/locale.c
+++ b/locale.c
@@ -232,7 +232,8 @@ Perl_new_collate(pTHX_ const char *newcoll)
const Size_t fb = strxfrm(xbuf, "ab", XFRMBUFSIZE);
const SSize_t mult = fb - fa;
if (mult < 1)
- Perl_croak(aTHX_ "strxfrm() gets absurd");
+ Perl_croak(aTHX_ "panic: strxfrm() gets absurd - a => %"UVuf", ab => %"UVuf,
+ (UV) fa, (UV) fb);
PL_collxfrm_base = (fa > (Size_t)mult) ? (fa - mult) : 0;
PL_collxfrm_mult = mult;
}
diff --git a/pod/perldiag.pod b/pod/perldiag.pod
index 0ce1c8d900..d4373d6b3a 100644
--- a/pod/perldiag.pod
+++ b/pod/perldiag.pod
@@ -3557,6 +3557,12 @@ scalar's string buffer.
(P) The sv_insert() routine was told to remove more string than there
was string.
+=item panic: strxfrm() gets absurd - a => %u, ab => %u
+
+(P) The interpreter's sanity check of the C function strxfrm() failed.
+In your current locale the returned transformation of the string "ab" is
+shorter than that of the string "a", which makes no sense.
+
=item panic: top_env
(P) The compiler attempted to do a goto, or something weird like that.
diff --git a/t/porting/diag.t b/t/porting/diag.t
index a3f627264a..eddb535a53 100644
--- a/t/porting/diag.t
+++ b/t/porting/diag.t
@@ -486,7 +486,6 @@ Size magic not implemented
%s%s on %s %s %s
Starting Full Screen process with flag=%d, mytype=%d
Starting PM process with flag=%d, mytype=%d
-strxfrm() gets absurd
SWASHNEW didn't return an HV ref
-T and -B not implemented on filehandles
The flock() function is not implemented on NetWare