summaryrefslogtreecommitdiff
path: root/lib/Unicode
diff options
context:
space:
mode:
authorKarl Williamson <public@khwilliamson.com>2014-02-28 10:27:49 -0700
committerKarl Williamson <public@khwilliamson.com>2014-03-01 20:12:16 -0700
commit014627eb95f9f2400c533d9fa9086a73f8fe0800 (patch)
tree11dc12c1a01793fc6a5212b8bdfadce7c4afb93d /lib/Unicode
parentebdc9bc900a67a13b31e9c1e7f689bfc3becc19a (diff)
downloadperl-014627eb95f9f2400c533d9fa9086a73f8fe0800.tar.gz
Unicode/UCD.t: Fix broken test
The test file special cases certain properties by name. However, it turns out that a Unihan property that isn't normally compiled by Perl also should be included. And all these properties share the same format given in their files. So, instead of using the property names, use that format; this leads to code which is general, and simpler at the same time.
Diffstat (limited to 'lib/Unicode')
-rw-r--r--lib/Unicode/UCD.t8
1 files changed, 2 insertions, 6 deletions
diff --git a/lib/Unicode/UCD.t b/lib/Unicode/UCD.t
index 61d1e7246a..5ed15c61d8 100644
--- a/lib/Unicode/UCD.t
+++ b/lib/Unicode/UCD.t
@@ -1761,12 +1761,8 @@ foreach my $prop (sort(keys %props), sort keys %legacy_props) {
next PROPERTY;
}
} # Otherwise, the map is to a simple scalar
- elsif ($full_name =~ # These maps are in hex
- / ^ ( Simple_ )? ( Case_Folding
- | ( Lower
- | Title
- | Upper ) case_Mapping ) $ /x)
- {
+ elsif (defined $file_format && $file_format eq 'ax') {
+ # These maps are in hex
$invmap_ref->[$i] = sprintf("%X", $invmap_ref->[$i]);
}
elsif ($format eq 'ad' || $format eq 'ale') {