Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 722f7ef

Browse files
committed
Correction for mathematical properties in Unicode converison maps.
Patches contributed by Eiji Tokuya (e-tokuya@sankyo-unyu.co.jp)
1 parent d32422f commit 722f7ef

18 files changed

+350
-34
lines changed

src/backend/utils/mb/Unicode/UCS_to_BIG5.pl

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# Copyright 2001 by PostgreSQL Global Development Group
44
#
5-
# $Id: UCS_to_BIG5.pl,v 1.1 2000/10/30 10:40:29 ishii Exp $
5+
# $Id: UCS_to_BIG5.pl,v 1.2 2001/04/16 06:10:18 ishii Exp $
66
#
77
# Generate UTF-8 <--> BIG5 code conversion tables from
88
# map files provided by Unicode organization.
@@ -32,7 +32,7 @@
3232
( $c, $u, $rest ) = split;
3333
$ucs = hex($u);
3434
$code = hex($c);
35-
if( $code >= 0x80 && $ucs >= 0x100 ){
35+
if( $code >= 0x80 && $ucs >= 0x0080 ){
3636
$utf = &ucs2utf($ucs);
3737
if( $array{ $utf } ne "" ){
3838
printf STDERR "Warning: duplicate unicode: %04x\n",$ucs;
@@ -81,7 +81,7 @@
8181
( $c, $u, $rest ) = split;
8282
$ucs = hex($u);
8383
$code = hex($c);
84-
if( $code >= 0x80 && $ucs >= 0x100 ){
84+
if( $code >= 0x80 && $ucs >= 0x0080 ){
8585
$utf = &ucs2utf($ucs);
8686
if( $array{ $code } ne "" ){
8787
printf STDERR "Warning: duplicate code: %04x\n",$ucs;

src/backend/utils/mb/Unicode/UCS_to_EUC_CN.pl

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# Copyright 2001 by PostgreSQL Global Development Group
44
#
5-
# $Id: UCS_to_EUC_CN.pl,v 1.1 2000/10/30 10:40:29 ishii Exp $
5+
# $Id: UCS_to_EUC_CN.pl,v 1.2 2001/04/16 06:10:18 ishii Exp $
66
#
77
# Generate UTF-8 <--> EUC_CN code conversion tables from
88
# map files provided by Unicode organization.
@@ -32,7 +32,7 @@
3232
( $c, $u, $rest ) = split;
3333
$ucs = hex($u);
3434
$code = hex($c);
35-
if( $code >= 0x80 && $ucs >= 0x100 ){
35+
if( $code >= 0x80 && $ucs >= 0x0080 ){
3636
$utf = &ucs2utf($ucs);
3737
if( $array{ $utf } ne "" ){
3838
printf STDERR "Warning: duplicate unicode: %04x\n",$ucs;
@@ -81,7 +81,7 @@
8181
( $c, $u, $rest ) = split;
8282
$ucs = hex($u);
8383
$code = hex($c);
84-
if( $code >= 0x80 && $ucs >= 0x100 ){
84+
if( $code >= 0x80 && $ucs >= 0x0080 ){
8585
$utf = &ucs2utf($ucs);
8686
if( $array{ $code } ne "" ){
8787
printf STDERR "Warning: duplicate code: %04x\n",$ucs;

src/backend/utils/mb/Unicode/UCS_to_EUC_JP.pl

+7-7
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# Copyright 2001 by PostgreSQL Global Development Group
44
#
5-
# $Id: UCS_to_EUC_JP.pl,v 1.1 2000/10/30 10:40:29 ishii Exp $
5+
# $Id: UCS_to_EUC_JP.pl,v 1.2 2001/04/16 06:10:18 ishii Exp $
66
#
77
# Generate UTF-8 <--> EUC_JP code conversion tables from
88
# map files provided by Unicode organization.
@@ -48,7 +48,7 @@
4848
( $c, $u, $rest ) = split;
4949
$ucs = hex($u);
5050
$code = hex($c);
51-
if( $code >= 0x80 && $ucs >= 0x100 ){
51+
if( $code >= 0x80 && $ucs >= 0x0080 ){
5252
$utf = &ucs2utf($ucs);
5353
if( $array{ $utf } ne "" ){
5454
printf STDERR "Warning: duplicate unicode: %04x\n",$ucs;
@@ -77,7 +77,7 @@
7777
( $s, $c, $u, $rest ) = split;
7878
$ucs = hex($u);
7979
$code = hex($c);
80-
if( $code >= 0x80 && $ucs >= 0x100 ){
80+
if( $code >= 0x80 && $ucs >= 0x0080 ){
8181
$utf = &ucs2utf($ucs);
8282
if( $array{ $utf } ne "" ){
8383
printf STDERR "Warning: duplicate unicode: %04x\n",$ucs;
@@ -105,7 +105,7 @@
105105
( $c, $u, $rest ) = split;
106106
$ucs = hex($u);
107107
$code = hex($c);
108-
if( $code >= 0x80 && $ucs >= 0x100 ){
108+
if( $code >= 0x80 && $ucs >= 0x0080 ){
109109
$utf = &ucs2utf($ucs);
110110
if( $array{ $utf } ne "" ){
111111
printf STDERR "Warning: duplicate unicode: %04x\n",$ucs;
@@ -160,7 +160,7 @@
160160
( $c, $u, $rest ) = split;
161161
$ucs = hex($u);
162162
$code = hex($c);
163-
if( $code >= 0x80 && $ucs >= 0x100 ){
163+
if( $code >= 0x80 && $ucs >= 0x0080 ){
164164
$utf = &ucs2utf($ucs);
165165
if( $array{ $code } ne "" ){
166166
printf STDERR "Warning: duplicate code: %04x\n",$ucs;
@@ -190,7 +190,7 @@
190190
( $s, $c, $u, $rest ) = split;
191191
$ucs = hex($u);
192192
$code = hex($c);
193-
if( $code >= 0x80 && $ucs >= 0x100 ){
193+
if( $code >= 0x80 && $ucs >= 0x0080 ){
194194
$utf = &ucs2utf($ucs);
195195
if( $array{ $code } ne "" ){
196196
printf STDERR "Warning: duplicate code: %04x\n",$ucs;
@@ -219,7 +219,7 @@
219219
( $c, $u, $rest ) = split;
220220
$ucs = hex($u);
221221
$code = hex($c);
222-
if( $code >= 0x80 && $ucs >= 0x100 ){
222+
if( $code >= 0x80 && $ucs >= 0x0080 ){
223223
$utf = &ucs2utf($ucs);
224224
if( $array{ $code } ne "" ){
225225
printf STDERR "Warning: duplicate code: %04x\n",$ucs;

src/backend/utils/mb/Unicode/UCS_to_EUC_KR.pl

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# Copyright 2001 by PostgreSQL Global Development Group
44
#
5-
# $Id: UCS_to_EUC_KR.pl,v 1.1 2000/10/30 10:40:29 ishii Exp $
5+
# $Id: UCS_to_EUC_KR.pl,v 1.2 2001/04/16 06:10:18 ishii Exp $
66
#
77
# Generate UTF-8 <--> EUC_KR code conversion tables from
88
# map files provided by Unicode organization.
@@ -32,7 +32,7 @@
3232
( $c, $u, $rest ) = split;
3333
$ucs = hex($u);
3434
$code = hex($c);
35-
if( $code >= 0x80 && $ucs >= 0x100 ){
35+
if( $code >= 0x80 && $ucs >= 0x0080 ){
3636
$utf = &ucs2utf($ucs);
3737
if( $array{ $utf } ne "" ){
3838
printf STDERR "Warning: duplicate unicode: %04x\n",$ucs;
@@ -81,7 +81,7 @@
8181
( $c, $u, $rest ) = split;
8282
$ucs = hex($u);
8383
$code = hex($c);
84-
if( $code >= 0x80 && $ucs >= 0x100 ){
84+
if( $code >= 0x80 && $ucs >= 0x0080 ){
8585
$utf = &ucs2utf($ucs);
8686
if( $array{ $code } ne "" ){
8787
printf STDERR "Warning: duplicate code: %04x\n",$ucs;

src/backend/utils/mb/Unicode/UCS_to_EUC_TW.pl

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# Copyright 2001 by PostgreSQL Global Development Group
44
#
5-
# $Id: UCS_to_EUC_TW.pl,v 1.1 2000/10/30 10:40:29 ishii Exp $
5+
# $Id: UCS_to_EUC_TW.pl,v 1.2 2001/04/16 06:10:18 ishii Exp $
66
#
77
# Generate UTF-8 <--> EUC_TW code conversion tables from
88
# map files provided by Unicode organization.
@@ -33,7 +33,7 @@
3333
( $c, $u, $rest ) = split;
3434
$ucs = hex($u);
3535
$code = hex($c);
36-
if( $code >= 0x80 && $ucs >= 0x100 ){
36+
if( $code >= 0x80 && $ucs >= 0x0080 ){
3737
$utf = &ucs2utf($ucs);
3838
if( $array{ $utf } ne "" ){
3939
printf STDERR "Warning: duplicate unicode: %04x\n",$ucs;
@@ -92,7 +92,7 @@
9292
( $c, $u, $rest ) = split;
9393
$ucs = hex($u);
9494
$code = hex($c);
95-
if( $code >= 0x80 && $ucs >= 0x100 ){
95+
if( $code >= 0x80 && $ucs >= 0x0080 ){
9696
$utf = &ucs2utf($ucs);
9797
if( $array{ $code } ne "" ){
9898
printf STDERR "Warning: duplicate code: %04x\n",$ucs;

src/backend/utils/mb/Unicode/UCS_to_SJIS.pl

+3-3
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# Copyright 2001 by PostgreSQL Global Development Group
44
#
5-
# $Id: UCS_to_SJIS.pl,v 1.2 2001/02/23 08:44:33 ishii Exp $
5+
# $Id: UCS_to_SJIS.pl,v 1.3 2001/04/16 06:10:18 ishii Exp $
66
#
77
# Generate UTF-8 <--> SJIS code conversion tables from
88
# map files provided by Unicode organization.
@@ -34,7 +34,7 @@
3434
( $c, $u, $rest ) = split;
3535
$ucs = hex($u);
3636
$code = hex($c);
37-
if( $code >= 0x80 && $ucs >= 0x100 ){
37+
if( $code >= 0x80 && $ucs >= 0x0080 ){
3838
$utf = &ucs2utf($ucs);
3939
if((( $code >= 0xed40 )
4040
&& ( $code <= 0xeefc ))
@@ -100,7 +100,7 @@
100100
( $c, $u, $rest ) = split;
101101
$ucs = hex($u);
102102
$code = hex($c);
103-
if( $code >= 0x80 && $ucs >= 0x100 ){
103+
if( $code >= 0x80 && $ucs >= 0x0080 ){
104104
$utf = &ucs2utf($ucs);
105105
$count++;
106106

src/backend/utils/mb/Unicode/big5_to_utf8.map

+10-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
static pg_local_to_utf LUmapBIG5[ 13701 ] = {
1+
static pg_local_to_utf LUmapBIG5[ 13710 ] = {
22
{0xa140, 0xe38080},
33
{0xa141, 0xefbc8c},
44
{0xa142, 0xe38081},
@@ -15,6 +15,7 @@ static pg_local_to_utf LUmapBIG5[ 13701 ] = {
1515
{0xa14d, 0xefb990},
1616
{0xa14e, 0xefbda4},
1717
{0xa14f, 0xefb992},
18+
{0xa150, 0xc2b7},
1819
{0xa151, 0xefb994},
1920
{0xa152, 0xefb995},
2021
{0xa153, 0xefb996},
@@ -77,6 +78,7 @@ static pg_local_to_utf LUmapBIG5[ 13701 ] = {
7778
{0xa1ae, 0xefbc86},
7879
{0xa1af, 0xefbc8a},
7980
{0xa1b0, 0xe280bb},
81+
{0xa1b1, 0xc2a7},
8082
{0xa1b2, 0xe38083},
8183
{0xa1b3, 0xe2978b},
8284
{0xa1b4, 0xe2978f},
@@ -108,6 +110,9 @@ static pg_local_to_utf LUmapBIG5[ 13701 ] = {
108110
{0xa1ce, 0xefb9a1},
109111
{0xa1cf, 0xefbc8b},
110112
{0xa1d0, 0xefbc8d},
113+
{0xa1d1, 0xc397},
114+
{0xa1d2, 0xc3b7},
115+
{0xa1d3, 0xc2b1},
111116
{0xa1d4, 0xe2889a},
112117
{0xa1d5, 0xefbc9c},
113118
{0xa1d6, 0xefbc9e},
@@ -155,7 +160,10 @@ static pg_local_to_utf LUmapBIG5[ 13701 ] = {
155160
{0xa241, 0xefbc8f},
156161
{0xa242, 0xefbcbc},
157162
{0xa243, 0xefbc84},
163+
{0xa244, 0xc2a5},
158164
{0xa245, 0xe38092},
165+
{0xa246, 0xc2a2},
166+
{0xa247, 0xc2a3},
159167
{0xa248, 0xefbc85},
160168
{0xa249, 0xefbca0},
161169
{0xa24a, 0xe28483},
@@ -172,6 +180,7 @@ static pg_local_to_utf LUmapBIG5[ 13701 ] = {
172180
{0xa255, 0xe38e8e},
173181
{0xa256, 0xe38e8f},
174182
{0xa257, 0xe38f84},
183+
{0xa258, 0xc2b0},
175184
{0xa259, 0xe58599},
176185
{0xa25a, 0xe5859b},
177186
{0xa25b, 0xe5859e},

src/backend/utils/mb/Unicode/euc_cn_to_utf8.map

+20-1
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1-
static pg_local_to_utf LUmapEUC_CN[ 7426 ] = {
1+
static pg_local_to_utf LUmapEUC_CN[ 7445 ] = {
22
{0xa1a1, 0xe38080},
33
{0xa1a2, 0xe38081},
44
{0xa1a3, 0xe38082},
55
{0xa1a4, 0xe383bb},
66
{0xa1a5, 0xcb89},
77
{0xa1a6, 0xcb87},
8+
{0xa1a7, 0xc2a8},
89
{0xa1a8, 0xe38083},
910
{0xa1a9, 0xe38085},
1011
{0xa1aa, 0xe28095},
@@ -29,6 +30,9 @@ static pg_local_to_utf LUmapEUC_CN[ 7426 ] = {
2930
{0xa1bd, 0xe38097},
3031
{0xa1be, 0xe38090},
3132
{0xa1bf, 0xe38091},
33+
{0xa1c0, 0xc2b1},
34+
{0xa1c1, 0xc397},
35+
{0xa1c2, 0xc3b7},
3236
{0xa1c3, 0xe288b6},
3337
{0xa1c4, 0xe288a7},
3438
{0xa1c5, 0xe288a8},
@@ -61,13 +65,16 @@ static pg_local_to_utf LUmapEUC_CN[ 7426 ] = {
6165
{0xa1e0, 0xe288b4},
6266
{0xa1e1, 0xe29982},
6367
{0xa1e2, 0xe29980},
68+
{0xa1e3, 0xc2b0},
6469
{0xa1e4, 0xe280b2},
6570
{0xa1e5, 0xe280b3},
6671
{0xa1e6, 0xe28483},
6772
{0xa1e7, 0xefbc84},
73+
{0xa1e8, 0xc2a4},
6874
{0xa1e9, 0xefbfa0},
6975
{0xa1ea, 0xefbfa1},
7076
{0xa1eb, 0xe280b0},
77+
{0xa1ec, 0xc2a7},
7178
{0xa1ed, 0xe28496},
7279
{0xa1ee, 0xe29886},
7380
{0xa1ef, 0xe29885},
@@ -536,19 +543,31 @@ static pg_local_to_utf LUmapEUC_CN[ 7426 ] = {
536543
{0xa7f0, 0xd18e},
537544
{0xa7f1, 0xd18f},
538545
{0xa8a1, 0xc481},
546+
{0xa8a2, 0xc3a1},
539547
{0xa8a3, 0xc78e},
548+
{0xa8a4, 0xc3a0},
540549
{0xa8a5, 0xc493},
550+
{0xa8a6, 0xc3a9},
541551
{0xa8a7, 0xc49b},
552+
{0xa8a8, 0xc3a8},
542553
{0xa8a9, 0xc4ab},
554+
{0xa8aa, 0xc3ad},
543555
{0xa8ab, 0xc790},
556+
{0xa8ac, 0xc3ac},
544557
{0xa8ad, 0xc58d},
558+
{0xa8ae, 0xc3b3},
545559
{0xa8af, 0xc792},
560+
{0xa8b0, 0xc3b2},
546561
{0xa8b1, 0xc5ab},
562+
{0xa8b2, 0xc3ba},
547563
{0xa8b3, 0xc794},
564+
{0xa8b4, 0xc3b9},
548565
{0xa8b5, 0xc796},
549566
{0xa8b6, 0xc798},
550567
{0xa8b7, 0xc79a},
551568
{0xa8b8, 0xc79c},
569+
{0xa8b9, 0xc3bc},
570+
{0xa8ba, 0xc3aa},
552571
{0xa8c5, 0xe38485},
553572
{0xa8c6, 0xe38486},
554573
{0xa8c7, 0xe38487},

0 commit comments

Comments
 (0)