Revision history for Perl extension Unicode::Normalize.
+0.14 Sat Feb 02 20:40:14 2002
+ - synchronization with bleadperl.
+ - Change 14128: by Arthur
+ - Change 14129: by jhi
+ - Change 14156:
+ - Change 14199: by Nikola Knezevic
+ - Change 14308: by Benjamin Goldberg
+ - Change 14370: by jhi
+
+0.13 Sat Dec 01 11:42:43 2001
+ - modify Makefile.PL to enable rebuild.
+ (This problem is pointed out by David Dyck.)
+ - Change 13388: by Jarkko Hietaniemi.
+
0.12 Wed Nov 29 22:49:02 2001
- documentation in .pod is appended to .pm and the .pod is removed.
(only POD in NON-XS refers to Lingua::KO::Hangul::Util.)
use warnings;
use Carp;
-our $VERSION = '0.13';
+our $VERSION = '0.14';
our $PACKAGE = __PACKAGE__;
require Exporter;
http://homepage1.nifty.com/nomenclator/perl/
- Copyright(C) 2001, SADAHIRO Tomoyuki. Japan. All rights reserved.
+ Copyright(C) 2001-2002, SADAHIRO Tomoyuki. Japan. All rights reserved.
This program is free software; you can redistribute it and/or
modify it under the same terms as Perl itself.
#endif /* uvuni_to_utf8 */
/* Perl 5.6.1 ? */
-#ifndef utf8n_to_uvchr
-#define utf8n_to_uvchr utf8_to_uv
-#endif /* utf8n_to_uvchr */
+#ifndef utf8n_to_uvuni
+#define utf8n_to_uvuni utf8_to_uv
+#endif /* utf8n_to_uvuni */
/* At present, char > 0x10ffff are unaffected without complaint, right? */
#define VALID_UTF_MAX (0x10ffff)
s = (U8*)SvPV(src,srclen);
e = s + srclen;
for(p = s; p < e;){
- uv = utf8n_to_uvchr(p, e - p, &retlen, 0);
+ uv = utf8n_to_uvuni(p, e - p, &retlen, 0);
p += retlen;
if(Hangul_IsS(uv)) sv_cat_decompHangul(dst, uv);
else {
U8 *cc_in;
STRLEN cc_len, cc_iter, cc_pos;
- uv = utf8n_to_uvchr(p, e - p, &retlen, 0);
+ uv = utf8n_to_uvuni(p, e - p, &retlen, 0);
curCC = getCombinClass(uv);
p += retlen;
stk_cc[cc_pos].pos = cc_pos;
while(p < e) {
- uv = utf8n_to_uvchr(p, e - p, &retlen, 0);
+ uv = utf8n_to_uvuni(p, e - p, &retlen, 0);
curCC = getCombinClass(uv);
if(!curCC) break;
p += retlen;
for(p = s; p < e;){
if(beginning) {
- uvS = utf8n_to_uvchr(p, e - p, &retlen, 0);
+ uvS = utf8n_to_uvuni(p, e - p, &retlen, 0);
p += retlen;
if (getCombinClass(uvS)){ /* no Starter found yet */
/* to the next Starter */
while(p < e) {
- uv = utf8n_to_uvchr(p, e - p, &retlen, 0);
+ uv = utf8n_to_uvuni(p, e - p, &retlen, 0);
p += retlen;
curCC = getCombinClass(uv);
}
uvS = uv;
} /* for */
-
SvCUR_set(dst, d - (U8*)SvPVX(dst));
RETVAL = dst;
OUTPUT:
-Unicode/Normalize version 0.12
+Unicode/Normalize version 0.14
===================================
Unicode::Normalize - normalized forms of Unicode text
make test
make install
+If you decide to install the NoXS version after trying to build the XS,
+type the following:
+
+ make clean
+ perl Makefile.PL noxs
+ make
+ make test
+ make install
+
DEPENDENCIES
This module requires these other modules and libraries:
Exporter
File::Copy
File::Spec
-unicore/CombiningClass.pl or unicode/CombiningClass.pl
-unicore/Decomposition.pl or unicode/Decomposition.pl
-unicore/CompositionExclusions.txt or unicode/CompExcl.txt
-and for the Non-XS version, in addition to the above,
-Lingua::KO::Hangul::Util 0.06
+unicore/CombiningClass.pl
+ (or unicode/CombiningClass.pl)
+unicore/Decomposition.pl
+ (or unicode/Decomposition.pl)
+unicore/CompositionExclusions.txt
+ (or unicode/CompExcl.txt)
+
+# CAVEAT:
+# In bleadperl, unicore/CompExcl.txt is renamed
+# unicore/CompositionExclusions.txt.
+
+And for the NoXS version, in addition to the above,
+
+ Lingua::KO::Hangul::Util 0.06
+
+is required.
COPYRIGHT AND LICENCE
http://homepage1.nifty.com/nomenclator/perl/
- Copyright(C) 2001, SADAHIRO Tomoyuki. Japan. All rights reserved.
+ Copyright(C) 2001-2002, SADAHIRO Tomoyuki. Japan. All rights reserved.
- This program is free software; you can redistribute it and/or
+ This program is free software; you can redistribute it and/or
modify it under the same terms as Perl itself.
&& 0x1E14 == getComposite(0x0112, 0x0300)
&& 0xAC00 == getComposite(0x1100, 0x1161)
&& 0xADF8 == getComposite(0x1100, 0x1173)
- && ! getComposite(0x1100, 0x11AF)
- && ! getComposite(0x1173, 0x11AF)
+ && ! defined getComposite(0x1100, 0x11AF)
+ && ! defined getComposite(0x1173, 0x11AF)
&& 0xAE00 == getComposite(0xADF8, 0x11AF)
? "ok" : "not ok", " 5\n";
ok(hexNFD("0000 0041 0000 0000"), "0000 0041 0000 0000");
# should be unary.
-ok(NFC "\x{41}\x{0302}\x{0301}\x62" eq "\x{1EA4}\x62");
-ok(NFD "\x{E0}\x{AC00}" eq "\x{61}\x{0300}\x{1100}\x{1161}");
+my $str11 = pack('U*', 0x41, 0x0302, 0x0301, 0x62);
+my $str12 = pack('U*', 0x1EA4, 0x62);
+ok(NFC $str11 eq $str12);
+
+my $str21 = pack('U*', 0xE0, 0xAC00);
+my $str22 = pack('U*', 0x61, 0x0300, 0x1100, 0x1161);
+ok(NFD $str21 eq $str22);