diff options
author | Karl Williamson <public@khwilliamson.com> | 2012-06-02 12:05:34 -0600 |
---|---|---|
committer | Karl Williamson <public@khwilliamson.com> | 2012-06-02 12:19:04 -0600 |
commit | fe3193b514b01b0a636361da0103ed33393cf9c4 (patch) | |
tree | fe33d9a73a7aa6e6066234dd889daa760489cf49 /lib/charnames.t | |
parent | c292d35a225572156ccde6f3a812f532f4347fad (diff) | |
download | perl-fe3193b514b01b0a636361da0103ed33393cf9c4.tar.gz |
mktables: Convert to BELL meaning U+1F514
As a result of the Unicode 6.0 mistake of using "BELL" to refer to
a different code point, Perl has deprecated use of this name for 2 major
release cycles, while not fully implementing Unicode in the interim, to
allow any affected code to migrate to the new name
This commit now switches to the new meaning of BELL.
Diffstat (limited to 'lib/charnames.t')
-rw-r--r-- | lib/charnames.t | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/lib/charnames.t b/lib/charnames.t index 6c2b54d017..ff94a82d26 100644 --- a/lib/charnames.t +++ b/lib/charnames.t @@ -295,11 +295,11 @@ is("\N{BOM}", chr(0xFEFF), 'Verify "\N{BOM}" is correct'); my $ok = ! grep { /"HORIZONTAL TABULATION" is deprecated.*"CHARACTER TABULATION"/ } @WARN; ok($ok, '... and doesnt give deprecated warning'); - # XXX These tests should be changed for 5.16, when we convert BELL to the - # Unicode version. - is("\N{BELL}", "\a", 'Verify "\N{BELL}" eq "\a"'); - my $ok = grep { /"BELL" is deprecated.*"ALERT"/ } @WARN; - ok($ok, '... and that gives correct deprecated warning'); + if ($^V lt v5.17.0) { + is("\N{BELL}", "\a", 'Verify "\N{BELL}" eq "\a"'); + my $ok = grep { /"BELL" is deprecated.*"ALERT"/ } @WARN; + ok($ok, '... and that gives correct deprecated warning'); + } no warnings 'deprecated'; @@ -365,7 +365,7 @@ is(charnames::viacode("U+00000000000FEED"), "ARABIC LETTER WAW ISOLATED FORM", ' is("\N{EOT}", "\N{END OF TRANSMISSION}", 'Verify "\N{EOT}" eq "\N{END OF TRANSMISSION}"'); is("\N{ENQ}", "\N{ENQUIRY}", 'Verify "\N{ENQ}" eq "\N{ENQUIRY}"'); is("\N{ACK}", "\N{ACKNOWLEDGE}", 'Verify "\N{ACK}" eq "\N{ACKNOWLEDGE}"'); - is("\N{BEL}", "\N{BELL}", 'Verify "\N{BEL}" eq "\N{BELL}"'); + is("\N{BEL}", "\N{BELL}", 'Verify "\N{BEL}" eq "\N{BELL}"') if $^V lt v5.17.0; is("\N{BS}", "\N{BACKSPACE}", 'Verify "\N{BS}" eq "\N{BACKSPACE}"'); is("\N{HT}", "\N{HORIZONTAL TABULATION}", 'Verify "\N{HT}" eq "\N{HORIZONTAL TABULATION}"'); is("\N{LF}", "\N{LINE FEED (LF)}", 'Verify "\N{LF}" eq "\N{LINE FEED (LF)}"'); @@ -1013,14 +1013,14 @@ is("\N{U+1D0C5}", "\N{BYZANTINE MUSICAL SYMBOL FTHORA SKLIRON CHROMA VASIS}", 'V my $decimal = hex $code; # The Unicode version 1 name is used instead of any that are - # marked <control> + # marked <control>. $name = $u1name if $name eq "<control>"; - $name = 'ALERT' if $decimal == 7; + # In earlier Perls, we reject this code point's name (BELL) + $name = "" if $^V lt v5.17.0 && $decimal == 0x1F514; - # XXX This test should be changed for 5.16 when we convert to use - # Unicode's BELL - $name = "" if $decimal == 0x1F514; + # ALERT overrides BELL + $name = 'ALERT' if $decimal == 7; # Some don't have names, leave those array elements undefined next unless $name; |