# Revision history for Perl extension Encode.
#
-# $Id: Changes,v 1.74 2002/05/28 18:33:15 dankogai Exp dankogai $
+# $Id: Changes,v 1.75 2002/06/01 18:07:49 dankogai Exp dankogai $
#
-$Revision: 1.74 $ $Date: 2002/05/28 18:33:15 $
+$Revision: 1.75 $ $Date: 2002/06/01 18:07:49 $
+! lib/Encode/Alias.pm t/Alias.t lib/Encode/Supported.pod TW/TW.pm
+ glibc compliance cited by Autrijus.
+ http://www.li18nux.org/docs/html/CodesetAliasTable-V10.html
+! bin/enc2xs bin/piconv
+ Subject: Re: forewarning: usedevel and versiononly
+ Message-Id: <20020529081515.D570.H.M.BRAND@hccnet.nl>
+
+1.74 2002/05/28 18:33:15
+ ucm/null.ucm ucm/ctrl.ucm
! Makefile.PL bin/enc2xs lib/Encode/Supported.pod
"null" and "ascii-ctrl" encodings added upon the request of Autrijus
Typo fixes and improvements by jhi
Message-Id: <200204010201.FAA03564@alpha.hut.fi>, et al.
-1.11 $Date: 2002/05/28 18:33:15 $
+1.11 $Date: 2002/06/01 18:07:49 $
+ t/encoding.t
+ t/jperl.t
! MANIFEST
#
-# $Id: Encode.pm,v 1.74 2002/05/28 18:33:54 dankogai Exp dankogai $
+# $Id: Encode.pm,v 1.75 2002/06/01 18:07:42 dankogai Exp $
#
package Encode;
use strict;
-our $VERSION = do { my @r = (q$Revision: 1.74 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
+our $VERSION = do { my @r = (q$Revision: 1.75 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
our $DEBUG = 0;
use XSLoader ();
XSLoader::load(__PACKAGE__, $VERSION);
die "Encode::TW not supported on EBCDIC\n";
}
}
-our $VERSION = do { my @r = (q$Revision: 1.25 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
+our $VERSION = do { my @r = (q$Revision: 1.26 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
use Encode;
use XSLoader;
--------------------------------------------------------------------
big5-eten /\bbig-?5$/i Big5 encoding (with ETen extensions)
/\bbig5-?et(en)?$/i
+ /\btca-?big5$/i
big5-hkscs /\bbig5-?hk(scs)?$/i
+ /\bhk(scs)?-?big5$/i
Big5 + Cantonese characters in Hong Kong
MacChineseTrad Big5 + Apple Vendor Mappings
cp950 Code Page 950
use strict;
use Getopt::Std;
my @orig_ARGV = @ARGV;
-our $VERSION = do { my @r = (q$Revision: 1.29 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
+our $VERSION = do { my @r = (q$Revision: 1.30 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
# These may get re-ordered.
# RAW is a do_now as inserted by &enter
#!./perl
-# $Id: piconv,v 1.24 2002/04/22 02:45:50 dankogai Exp $
+# $Id: piconv,v 1.25 2002/06/01 18:07:49 dankogai Exp dankogai $
#
use 5.8.0;
use strict;
package Encode::Alias;
use strict;
use Encode;
-our $VERSION = do { my @r = (q$Revision: 1.31 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
+our $VERSION = do { my @r = (q$Revision: 1.32 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
our $DEBUG = 0;
use base qw(Exporter);
# ASCII
define_alias(qr/^(?:US-?)ascii$/i => '"ascii"');
define_alias('C' => 'ascii');
+ define_alias(qr/\bISO[-_]?646[-_]?US$/i => '"ascii"');
# Allow variants of iso-8859-1 etc.
define_alias( qr/\biso[-_]?(\d+)[-_](\d+)$/i => '"iso-$1-$2"' );
# At least AIX has IBM-NNN (surprisingly...) instead of cpNNN.
# And Microsoft has their own naming (again, surprisingly).
# And windows-* is registered in IANA!
- define_alias( qr/\b(?:ibm|ms|windows)[-_]?(\d\d\d\d?)$/i => '"cp$1"');
+ define_alias( qr/\b(?:cp|ibm|ms|windows)[-_ ]?(\d{2,4})$/i => '"cp$1"');
# Sometimes seen with a leading zero.
# define_alias( qr/\bcp037\b/i => '"cp37"');
# for Encode::TW
define_alias( qr/\bbig-?5$/i => '"big5-eten"' );
define_alias( qr/\bbig5-?et(?:en)$/i => '"big5-eten"' );
+ define_alias( qr/\btca[-_]?big5$/i => '"big5-eten"' );
define_alias( qr/\bbig5-?hk(?:scs)?$/i => '"big5-hkscs"' );
+ define_alias( qr/\bhk(?:scs)?[-_]?big5$/i => '"big5-hkscs"' );
}
# utf8 is blessed :)
define_alias( qr/^UTF-8$/i => '"utf8"',);
Canonical Aliases Comments & References
----------------------------------------------------------------
- ascii US-ascii [ECMA]
+ ascii US-ascii ISO-646-US [ECMA]
ascii-ctrl Special Encoding
iso-8859-1 latin1 [ISO]
null Special Encoding
sub init_a2c{
%a2c = (
'US-ascii' => 'ascii',
+ 'ISO-646-US' => 'ascii',
'UTF-8' => 'utf8',
'UCS-2' => 'UCS-2BE',
'UCS2' => 'UCS-2BE',
'jis' => $ON_EBCDIC ? '' : '7bit-jis',
'big-5' => $ON_EBCDIC ? '' : 'big5-eten',
'zh_TW.Big5' => $ON_EBCDIC ? '' : 'big5-eten',
+ 'tca-big5' => $ON_EBCDIC ? '' : 'big5-eten',
'big5-hk' => $ON_EBCDIC ? '' : 'big5-hkscs',
+ 'hkscs-big5' => $ON_EBCDIC ? '' : 'big5-hkscs',
'GB_2312-80' => $ON_EBCDIC ? '' : 'euc-cn',
'KS_C_5601-1987' => $ON_EBCDIC ? '' : 'cp949',
#
my $v = $Encode::Alias::Winlatin2cp{$k};
$a2c{"Win" . ucfirst($k)} = "cp" . $v;
$a2c{"IBM-$v"} = $a2c{"MS-$v"} = "cp" . $v;
+ $a2c{"cp-" . $v} = "cp" . $v;
}
my @a2c = keys %a2c;
for my $k (@a2c){
#
-# $Id: ctrl.ucm,v 1.1 2002/05/28 18:33:15 dankogai Exp dankogai $
+# $Id: ctrl.ucm,v 1.1 2002/05/28 18:33:15 dankogai Exp $
#
<code_set_name> "ascii-ctrl"
<mb_cur_min> 1
#
-# $Id: null.ucm,v 1.1 2002/05/28 18:33:15 dankogai Exp dankogai $
+# $Id: null.ucm,v 1.1 2002/05/28 18:33:15 dankogai Exp $
#
<code_set_name> "null"
<mb_cur_min> 1