1#!./perl 2 3# This is a test for [perl #60508] which I can't figure out where else 4# to put it or what the underlying problem is, but it has to go somewhere. 5# --Schwern 6 7BEGIN { 8 chdir 't' if -d 't'; 9 require './test.pl'; 10 set_up_inc('../lib'); 11} 12 13use utf8; 14plan tests => 1; 15 16{ 17 my $expect = <<"EXPECT"; 18k1 = .... 19k2.1 = >\x{2022} 20k2.2 = \x{2022} 21EXPECT 22 utf8::encode($expect); 23 24 #local $TODO = "[perl #60508]"; 25 26 fresh_perl_is(<<'CODE', $expect, {}); 27binmode STDOUT, ":utf8"; 28sub f { $_[0] =~ s/([>X])//g; } 29 30$k1 = "." x 4 . ">>"; 31f($k1); 32print "k1 = $k1\n"; 33 34$k2 = "\x{f1}\x{2022}"; 35$k2 =~ s/([\360-\362])/>/g; 36print "k2.1 = $k2\n"; 37f($k2); 38print "k2.2 = $k2\n"; 39CODE 40} 41