summaryrefslogtreecommitdiff
path: root/dist/Storable
diff options
context:
space:
mode:
authorKarl Williamson <khw@cpan.org>2015-03-10 14:53:21 -0600
committerKarl Williamson <khw@cpan.org>2015-03-13 10:53:11 -0600
commit058b61c56b7b237ac98071c582133d56a78c72af (patch)
tree5ffc9b12f790196975b531a90ab814e10672766f /dist/Storable
parent410a87cf53faefde0612c4b86b028c140c5884fe (diff)
downloadperl-058b61c56b7b237ac98071c582133d56a78c72af.tar.gz
dist/Storable/t/utf8.t: Fix to work on early Perls
In commit 571d5cf7467f1af9ff1e6d751f49ac47e4f88380, I forgot that this is dual-lifed and may be used on early Perls. This commit allows that, but it will fail if such a Perl were to be used on an EBCDIC platform.
Diffstat (limited to 'dist/Storable')
-rw-r--r--dist/Storable/t/utf8.t6
1 files changed, 4 insertions, 2 deletions
diff --git a/dist/Storable/t/utf8.t b/dist/Storable/t/utf8.t
index dfb43eaa12..a8dd6cd317 100644
--- a/dist/Storable/t/utf8.t
+++ b/dist/Storable/t/utf8.t
@@ -32,8 +32,10 @@ is($x, ${thaw freeze \$x});
$x = join '', map {chr $_} (0..1023);
is($x, ${thaw freeze \$x});
-# Char in the range 127-255 (probably) in utf8
-$x = chr(utf8::unicode_to_native(175)) . chr (256);
+# Char in the range 127-255 (probably) in utf8. This just won't work for
+# EBCDIC for early Perls.
+$x = ($] lt 5.007_003) ? chr(175) : chr(utf8::unicode_to_native(175))
+ . chr (256);
chop $x;
is($x, ${thaw freeze \$x});