This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Properly handle the Unicode kIICore property
authorKarl Williamson <khw@cpan.org>
Sat, 4 Jul 2015 18:01:18 +0000 (12:01 -0600)
committerKarl Williamson <khw@cpan.org>
Wed, 29 Jul 2015 04:15:56 +0000 (22:15 -0600)
commitd963b40d95190da0752832d8df913f2b294844bf
treec2f485f10d8d9fba1e0cee21ef06b59e8532ab7d
parent8981bf2b79483d0f338ee86fb79b9e1872cf96ed
Properly handle the Unicode kIICore property

This property is not included in the standard Perl distribution, but it
is normative in the Unicode Unihan database and perl can be compiled to
include it.  This property is currently unique in that it operates much
like how Perl defines string truthfulness: non-empty values are
considered true.  That is \p{kIICore} matches all characters which have
a non-empty value for this property, plus the actual values have
meaning that may need to be examined in some circumstances.  These can
be retrieved via Unicode::UCD::prop_invmap().

Unicode 7.0 changed this property without my noticing, and went a very
different direction with it than I anticipated.  And the perl
interpreter would loop when trying to deal with it under some
circumstances.

This property is true for all 'core' Chinese/Japanese/Korean characters
that every implementation of CJK things should strive to handle, i.e., the
minimally acceptable set, though the values now specify a precedence as
their first letter, A, B, or C (I suppose this means one could implement
just the A level ones first).  The remaining letters in each value
encode the standards which were used as the source for the character.
In previous versions of the Standard, every non-null value was the
string "2.1".
charclass_invlists.h
lib/Unicode/UCD.pm
lib/Unicode/UCD.t
lib/unicore/mktables
lib/utf8_heavy.pl
regcharclass.h