diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2000-10-11 03:16:05 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2000-10-11 03:16:05 +0000 |
commit | b7018214460794b1717c970bae422221c10f4634 (patch) | |
tree | 306c57ab313580e284474f47ac03ef565e447063 /t | |
parent | c71f135dc8b214a7f302aedfa9ad2ec63490adc2 (diff) | |
download | perl-b7018214460794b1717c970bae422221c10f4634.tar.gz |
SvPV() (via mg_get() of sv_2pv()) can update the UTF8ness of the SVs.
p4raw-id: //depot/perl@7201
Diffstat (limited to 't')
-rwxr-xr-x | t/pragma/utf8.t | 32 |
1 files changed, 31 insertions, 1 deletions
diff --git a/t/pragma/utf8.t b/t/pragma/utf8.t index 1b6ca915ab..2b208cc167 100755 --- a/t/pragma/utf8.t +++ b/t/pragma/utf8.t @@ -10,7 +10,7 @@ BEGIN { } } -print "1..72\n"; +print "1..75\n"; my $test = 1; @@ -344,3 +344,33 @@ sub nok_bytes { $latin =~ s!(s)tr(?:aß|s+e)!$1tr.!; # \303\237 after the a } } + +{ + $_ = $dx = "\x{10f2}"; + s/($dx)/$dx$1/; + { + use bytes; + print "not " unless $_ eq "$dx$dx"; + print "ok $test\n"; + $test++; + } + + $_ = $dx = "\x{10f2}"; + s/($dx)/$1$dx/; + { + use bytes; + print "not " unless $_ eq "$dx$dx"; + print "ok $test\n"; + $test++; + } + + $dx = "\x{10f2}"; + $_ = "\x{10f2}\x{10f2}"; + s/($dx)($dx)/$1$2/; + { + use bytes; + print "not " unless $_ eq "$dx$dx"; + print "ok $test\n"; + $test++; + } +} |