diff options
author | Todd C. Miller <millert@cvs.openbsd.org> | 2004-08-09 18:10:42 +0000 |
---|---|---|
committer | Todd C. Miller <millert@cvs.openbsd.org> | 2004-08-09 18:10:42 +0000 |
commit | b30707e4885ca231ff72a496671faa7830e8002a (patch) | |
tree | ceefb7d8635e495c31ba663e183cdcad8a9b157c /gnu/usr.bin/perl/lib/utf8.t | |
parent | 3c5182ca6f3c3cb0d292743e65788c0b1d03b596 (diff) |
merge 5.8.5 into HEAD
remove now-unused files
crank libperl shared library major number
update Makefile.bsd-wrapper
tweak openbsd hints file for arm and m68k
Diffstat (limited to 'gnu/usr.bin/perl/lib/utf8.t')
-rw-r--r-- | gnu/usr.bin/perl/lib/utf8.t | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/gnu/usr.bin/perl/lib/utf8.t b/gnu/usr.bin/perl/lib/utf8.t index 33cd5966af5..576d90e5a81 100644 --- a/gnu/usr.bin/perl/lib/utf8.t +++ b/gnu/usr.bin/perl/lib/utf8.t @@ -37,7 +37,7 @@ no utf8; # Ironic, no? # # -plan tests => 143; +plan tests => 145; { # bug id 20001009.001 @@ -409,3 +409,19 @@ SKIP: { ok( utf8::is_utf8($b), " utf8::is_utf8 beyond"); # $b stays in UTF-8. ok( utf8::is_utf8($c), " utf8::is_utf8 unicode"); } + +{ + eval {utf8::encode("£")}; + like($@, qr/^Modification of a read-only value attempted/, + "utf8::encode should refuse to touch read-only values"); +} + +{ + my $a = "456\xb6"; + utf8::upgrade($a); + + my $b = "123456\xb6"; + $b =~ s/^...//; + utf8::upgrade($b); + is($b, $a, "utf8::upgrade OffsetOK"); +} |