Lots of spring cleaning. (No functional changes.)
[p5sagit/p5-mst-13.2.git] / ext / Storable / t / downgrade.t
CommitLineData
530b72ba 1#!./perl -w
2
3#
4# Copyright 2002, Larry Wall.
5#
6# You may redistribute only under the same terms as Perl 5, as specified
7# in the README file that comes with the distribution.
8#
9
10# I ought to keep this test easily backwards compatible to 5.004, so no
11# qr//;
12
13# This test checks downgrade behaviour on pre-5.8 perls when new 5.8 features
14# are encountered.
15
16sub BEGIN {
17 if ($ENV{PERL_CORE}){
18 chdir('t') if -d 't';
372cb964 19 @INC = ('.', '../lib');
20 } else {
21 unshift @INC, 't';
530b72ba 22 }
23 require Config; import Config;
24 if ($ENV{PERL_CORE} and $Config{'extensions'} !~ /\bStorable\b/) {
25 print "1..0 # Skip: Storable was not built\n";
26 exit 0;
27 }
530b72ba 28}
29
530b72ba 30use Test::More;
31use Storable 'thaw';
32
33use strict;
34use vars qw(@RESTRICT_TESTS %R_HASH %U_HASH $UTF8_CROAK $RESTRICTED_CROAK);
35
36@RESTRICT_TESTS = ('Locked hash', 'Locked hash placeholder',
37 'Locked keys', 'Locked keys placeholder',
38 );
39%R_HASH = (perl => 'rules');
40
bfe34c33 41if ($] > 5.007002) {
7e416500 42 # This is cheating. "\xdf" in Latin 1 is beta S, so will match \w if it
43 # is stored in utf8, not bytes.
44 # "\xdf" is y diaresis in EBCDIC (except for cp875, but so far no-one seems
45 # to use that) which has exactly the same properties for \w
46 # So the tests happen to pass.
530b72ba 47 my $utf8 = "Schlo\xdf" . chr 256;
48 chop $utf8;
49
7e416500 50 # \xe5 is V in EBCDIC. That doesn't have the same properties w.r.t. \w as
51 # an a circumflex, so we need to be explicit.
52
53 # and its these very properties we're trying to test - an edge case
54 # involving whether scalars are being stored in bytes or in utf8.
55 my $a_circumflex = (ord ('A') == 193 ? "\x47" : "\xe5");
56 %U_HASH = (map {$_, $_} 'castle', "ch${a_circumflex}teau", $utf8, chr 0x57CE);
530b72ba 57 plan tests => 169;
58} elsif ($] >= 5.006) {
59 plan tests => 59;
60} else {
61 plan tests => 67;
62}
63
64$UTF8_CROAK = qr/^Cannot retrieve UTF8 data in non-UTF8 perl/;
65$RESTRICTED_CROAK = qr/^Cannot retrieve restricted hash/;
66
67my %tests;
68{
69 local $/ = "\n\nend\n";
70 while (<DATA>) {
71 next unless /\S/s;
72 unless (/begin ([0-7]{3}) ([^\n]*)\n(.*)$/s) {
73 s/\n.*//s;
74 warn "Dodgy data in section starting '$_'";
75 next;
76 }
77 next unless oct $1 == ord 'A'; # Skip ASCII on EBCDIC, and vice versa
78 my $data = unpack 'u', $3;
79 $tests{$2} = $data;
80 }
81}
82
83# use Data::Dumper; $Data::Dumper::Useqq = 1; print Dumper \%tests;
84sub thaw_hash {
85 my ($name, $expected) = @_;
86 my $hash = eval {thaw $tests{$name}};
87 is ($@, '', "Thawed $name without error?");
88 isa_ok ($hash, 'HASH');
89 ok (defined $hash && eq_hash($hash, $expected),
90 "And it is the hash we expected?");
91 $hash;
92}
93
94sub thaw_scalar {
2aeb6432 95 my ($name, $expected, $bug) = @_;
530b72ba 96 my $scalar = eval {thaw $tests{$name}};
97 is ($@, '', "Thawed $name without error?");
98 isa_ok ($scalar, 'SCALAR', "Thawed $name?");
2aeb6432 99 if ($bug and $] == 5.006) {
100 # Aargh. <expletive> <expletive> 5.6.0's harness doesn't even honour
101 # TODO tests.
102 warn "# Test skipped because eq is buggy for certain Unicode cases in 5.6.0";
103 warn "# Please upgrade to 5.6.1\n";
104 ok ("I'd really like to fail this test on 5.6.0 but I'm told that CPAN auto-dependancies mess up, and certain vendors only ship 5.6.0. Get your vendor to ugrade. Else upgrade your vendor.");
105 # One such vendor being the folks who brought you LONG_MIN as a positive
106 # integer.
107 } else {
108 is ($$scalar, $expected, "And it is the data we expected?");
109 }
530b72ba 110 $scalar;
111}
112
113sub thaw_fail {
114 my ($name, $expected) = @_;
115 my $thing = eval {thaw $tests{$name}};
116 is ($thing, undef, "Thawed $name failed as expected?");
117 like ($@, $expected, "Error as predicted?");
118}
119
120sub test_locked_hash {
121 my $hash = shift;
122 my @keys = keys %$hash;
123 my ($key, $value) = each %$hash;
124 eval {$hash->{$key} = reverse $value};
125 like( $@, qr/^Modification of a read-only value attempted/,
126 'trying to change a locked key' );
127 is ($hash->{$key}, $value, "hash should not change?");
128 eval {$hash->{use} = 'perl'};
129 like( $@, qr/^Attempt to access disallowed key 'use' in a restricted hash/,
130 'trying to add another key' );
131 ok (eq_array([keys %$hash], \@keys), "Still the same keys?");
132}
133
134sub test_restricted_hash {
135 my $hash = shift;
136 my @keys = keys %$hash;
137 my ($key, $value) = each %$hash;
138 eval {$hash->{$key} = reverse $value};
139 is( $@, '',
140 'trying to change a restricted key' );
141 is ($hash->{$key}, reverse ($value), "hash should change");
142 eval {$hash->{use} = 'perl'};
143 like( $@, qr/^Attempt to access disallowed key 'use' in a restricted hash/,
144 'trying to add another key' );
145 ok (eq_array([keys %$hash], \@keys), "Still the same keys?");
146}
147
148sub test_placeholder {
149 my $hash = shift;
150 eval {$hash->{rules} = 42};
151 is ($@, '', 'No errors');
152 is ($hash->{rules}, 42, "New value added");
153}
154
155sub test_newkey {
156 my $hash = shift;
157 eval {$hash->{nms} = "http://nms-cgi.sourceforge.net/"};
158 is ($@, '', 'No errors');
159 is ($hash->{nms}, "http://nms-cgi.sourceforge.net/", "New value added");
160}
161
162# $Storable::DEBUGME = 1;
163thaw_hash ('Hash with utf8 flag but no utf8 keys', \%R_HASH);
164
165if (eval "use Hash::Util; 1") {
166 print "# We have Hash::Util, so test that the restricted hashes in <DATA> are valid\n";
167 for $Storable::downgrade_restricted (0, 1, undef, "cheese") {
168 my $hash = thaw_hash ('Locked hash', \%R_HASH);
169 test_locked_hash ($hash);
170 $hash = thaw_hash ('Locked hash placeholder', \%R_HASH);
171 test_locked_hash ($hash);
172 test_placeholder ($hash);
173
174 $hash = thaw_hash ('Locked keys', \%R_HASH);
175 test_restricted_hash ($hash);
176 $hash = thaw_hash ('Locked keys placeholder', \%R_HASH);
177 test_restricted_hash ($hash);
178 test_placeholder ($hash);
179 }
180} else {
181 print "# We don't have Hash::Util, so test that the restricted hashes downgrade\n";
182 my $hash = thaw_hash ('Locked hash', \%R_HASH);
183 test_newkey ($hash);
184 $hash = thaw_hash ('Locked hash placeholder', \%R_HASH);
185 test_newkey ($hash);
186 $hash = thaw_hash ('Locked keys', \%R_HASH);
187 test_newkey ($hash);
188 $hash = thaw_hash ('Locked keys placeholder', \%R_HASH);
189 test_newkey ($hash);
190 local $Storable::downgrade_restricted = 0;
191 thaw_fail ('Locked hash', $RESTRICTED_CROAK);
192 thaw_fail ('Locked hash placeholder', $RESTRICTED_CROAK);
193 thaw_fail ('Locked keys', $RESTRICTED_CROAK);
194 thaw_fail ('Locked keys placeholder', $RESTRICTED_CROAK);
195}
196
197if ($] >= 5.006) {
198 print "# We have utf8 scalars, so test that the utf8 scalars in <DATA> are valid\n";
2aeb6432 199 thaw_scalar ('Short 8 bit utf8 data', "\xDF", 1);
200 thaw_scalar ('Long 8 bit utf8 data', "\xDF" x 256, 1);
530b72ba 201 thaw_scalar ('Short 24 bit utf8 data', chr 0xC0FFEE);
202 thaw_scalar ('Long 24 bit utf8 data', chr (0xC0FFEE) x 256);
203} else {
204 print "# We don't have utf8 scalars, so test that the utf8 scalars downgrade\n";
205 thaw_fail ('Short 8 bit utf8 data', $UTF8_CROAK);
206 thaw_fail ('Long 8 bit utf8 data', $UTF8_CROAK);
207 thaw_fail ('Short 24 bit utf8 data', $UTF8_CROAK);
208 thaw_fail ('Long 24 bit utf8 data', $UTF8_CROAK);
209 local $Storable::drop_utf8 = 1;
210 my $bytes = thaw $tests{'Short 8 bit utf8 data as bytes'};
211 thaw_scalar ('Short 8 bit utf8 data', $$bytes);
212 thaw_scalar ('Long 8 bit utf8 data', $$bytes x 256);
213 $bytes = thaw $tests{'Short 24 bit utf8 data as bytes'};
214 thaw_scalar ('Short 24 bit utf8 data', $$bytes);
215 thaw_scalar ('Long 24 bit utf8 data', $$bytes x 256);
216}
217
bfe34c33 218if ($] > 5.007002) {
530b72ba 219 print "# We have utf8 hashes, so test that the utf8 hashes in <DATA> are valid\n";
220 my $hash = thaw_hash ('Hash with utf8 keys', \%U_HASH);
221 for (keys %$hash) {
222 my $l = 0 + /^\w+$/;
223 my $r = 0 + $hash->{$_} =~ /^\w+$/;
224 cmp_ok ($l, '==', $r, sprintf "key length %d", length $_);
225 cmp_ok ($l, '==', $_ eq "ch\xe5teau" ? 0 : 1);
226 }
227 if (eval "use Hash::Util; 1") {
228 print "# We have Hash::Util, so test that the restricted utf8 hash is valid\n";
229 my $hash = thaw_hash ('Locked hash with utf8 keys', \%U_HASH);
230 for (keys %$hash) {
231 my $l = 0 + /^\w+$/;
232 my $r = 0 + $hash->{$_} =~ /^\w+$/;
233 cmp_ok ($l, '==', $r, sprintf "key length %d", length $_);
234 cmp_ok ($l, '==', $_ eq "ch\xe5teau" ? 0 : 1);
235 }
236 test_locked_hash ($hash);
237 } else {
238 print "# We don't have Hash::Util, so test that the utf8 hash downgrades\n";
239 fail ("You can't get here [perl version $]]. This is a bug in the test.
240# Please send the output of perl -V to perlbug\@perl.org");
241 }
242} else {
243 print "# We don't have utf8 hashes, so test that the utf8 hashes downgrade\n";
244 thaw_fail ('Hash with utf8 keys', $UTF8_CROAK);
245 thaw_fail ('Locked hash with utf8 keys', $UTF8_CROAK);
246 local $Storable::drop_utf8 = 1;
247 my $what = $] < 5.006 ? 'pre 5.6' : '5.6';
248 my $expect = thaw $tests{"Hash with utf8 keys for $what"};
249 thaw_hash ('Hash with utf8 keys', $expect);
250 #foreach (keys %$expect) { print "'$_':\t'$expect->{$_}'\n"; }
251 #foreach (keys %$got) { print "'$_':\t'$got->{$_}'\n"; }
252 if (eval "use Hash::Util; 1") {
253 print "# We have Hash::Util, so test that the restricted hashes in <DATA> are valid\n";
254 fail ("You can't get here [perl version $]]. This is a bug in the test.
255# Please send the output of perl -V to perlbug\@perl.org");
256 } else {
257 print "# We don't have Hash::Util, so test that the restricted hashes downgrade\n";
258 my $hash = thaw_hash ('Locked hash with utf8 keys', $expect);
259 test_newkey ($hash);
260 local $Storable::downgrade_restricted = 0;
261 thaw_fail ('Locked hash with utf8 keys', $RESTRICTED_CROAK);
262 # Which croak comes first is a bit of an implementation issue :-)
263 local $Storable::drop_utf8 = 0;
264 thaw_fail ('Locked hash with utf8 keys', $RESTRICTED_CROAK);
265 }
266}
267__END__
268# A whole run of 2.x nfreeze data, uuencoded. The "mode bits" are the octal
269# value of 'A', the "file name" is the test name. Use make_downgrade.pl to
270# generate these.
271begin 101 Locked hash
2728!049`0````$*!7)U;&5S!`````1P97)L
273
274end
275
276begin 101 Locked hash placeholder
277C!049`0````(*!7)U;&5S!`````1P97)L#A0````%<G5L97,`
278
279end
280
281begin 101 Locked keys
2828!049`0````$*!7)U;&5S``````1P97)L
283
284end
285
286begin 101 Locked keys placeholder
287C!049`0````(*!7)U;&5S``````1P97)L#A0````%<G5L97,`
288
289end
290
291begin 101 Short 8 bit utf8 data
292&!047`L.?
293
294end
295
296begin 101 Short 8 bit utf8 data as bytes
297&!04*`L.?
298
299end
300
301begin 101 Long 8 bit utf8 data
302M!048```"`,.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?
303MPY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#
304MG\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?
305MPY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#
306MG\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?
307MPY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#
308MG\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?PY_#G\.?
309MPY_#G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PC[^N^+"/OZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/
354MOZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/
355MOZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N^+"/
356;OZ[XL(^_KOBPC[^N^+"/OZ[XL(^_KOBPC[^N
357
358end
359
360begin 101 Hash with utf8 flag but no utf8 keys
3618!049``````$*!7)U;&5S``````1P97)L
362
363end
364
365begin 101 Hash with utf8 keys
366M!049``````0*!F-A<W1L90`````&8V%S=&QE"@=C:.5T96%U``````=C:.5T
367D96%U%P/EGXX!`````^6?CA<'4V-H;&_#GP(````&4V-H;&_?
368
369end
370
371begin 101 Locked hash with utf8 keys
372M!049`0````0*!F-A<W1L900````&8V%S=&QE"@=C:.5T96%U!`````=C:.5T
373D96%U%P/EGXX%`````^6?CA<'4V-H;&_#GP8````&4V-H;&_?
374
375end
376
377begin 101 Hash with utf8 keys for pre 5.6
378M!049``````0*!F-A<W1L90`````&8V%S=&QE"@=C:.5T96%U``````=C:.5T
379D96%U"@/EGXX``````^6?C@H'4V-H;&_#GP(````&4V-H;&_?
380
381end
382
383begin 101 Hash with utf8 keys for 5.6
384M!049``````0*!F-A<W1L90`````&8V%S=&QE"@=C:.5T96%U``````=C:.5T
385D96%U%P/EGXX``````^6?CA<'4V-H;&_#GP(````&4V-H;&_?
386
387end
388
62cc3256 389begin 301 Locked hash
3908!049`0````$*!9FDDX6B!`````27A9F3
391
392end
393
394begin 301 Locked hash placeholder
395C!049`0````(.%`````69I).%H@H%F:23A:(`````!)>%F9,`
396
397end
398
399begin 301 Locked keys
4008!049`0````$*!9FDDX6B``````27A9F3
401
402end
403
404begin 301 Locked keys placeholder
405C!049`0````(.%`````69I).%H@H%F:23A:(`````!)>%F9,`
406
407end
408
409begin 301 Short 8 bit utf8 data
410&!047`HMS
411
412end
413
414begin 301 Short 8 bit utf8 data as bytes
415&!04*`HMS
416
417end
418
419begin 301 Long 8 bit utf8 data
7e416500 420M!048```"`(MSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
62cc3256 421MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
422M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
423MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
424M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
425MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
426M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
427MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
428M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
429MBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+
430M<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
4318BW.+<XMSBW.+<XMSBW.+<XMSBW.+<XMS
432
433end
434
435begin 301 Short 24 bit utf8 data
436*!047!OM30G-S50``
437
438end
439
440begin 301 Short 24 bit utf8 data as bytes
441*!04*!OM30G-S50``
442
443end
444
445begin 301 Long 24 bit utf8 data
7e416500 446M!048```&`/M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
62cc3256 447M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
448M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
449M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
450M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
451M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
452M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
453M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
454M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
455M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
456M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
457M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
458M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
459M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
460M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
461M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
462M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
463M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
464M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
465M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
466M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
467M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
468M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
469M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
470M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
471M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
472M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
473M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
474M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
475M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
476M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
477M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
478M5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M3
479M0G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S5?M30G-S
480-5?M30G-S5?M30G-S50``
481
482end
483
484begin 301 Hash with utf8 flag but no utf8 keys
4858!049``````$*!9FDDX6B``````27A9F3
486
487end
488
489begin 301 Hash with utf8 keys
7e416500 490M!049``````0*!X.(1Z.%@:0`````!X.(1Z.%@:0*!H.!HJ.3A0`````&@X&B
491FHY.%%P3<9')5`0````3<9')5%P?B@XB3EHMS`@````;B@XB3EM\`
62cc3256 492
493end
494
495begin 301 Locked hash with utf8 keys
7e416500 496M!049`0````0*!X.(1Z.%@:0$````!X.(1Z.%@:0*!H.!HJ.3A00````&@X&B
497FHY.%%P3<9')5!0````3<9')5%P?B@XB3EHMS!@````;B@XB3EM\`
62cc3256 498
499end
500
501begin 301 Hash with utf8 keys for pre 5.6
7e416500 502M!049``````0*!H.!HJ.3A0`````&@X&BHY.%"@B#B(M&HX6!I``````'@XA'
503GHX6!I`H'XH.(DY:+<P(````&XH.(DY;?"@3<9')5``````3<9')5
62cc3256 504
505end
506
507begin 301 Hash with utf8 keys for 5.6
7e416500 508M!049``````0*!H.!HJ.3A0`````&@X&BHY.%"@>#B$>CA8&D``````>#B$>C
62cc3256 509FA8&D%P?B@XB3EHMS`@````;B@XB3EM\7!-QD<E4`````!-QD<E4`
510
511end