summaryrefslogtreecommitdiff
path: root/encoding.c
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-01-13 14:29:12 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2008-01-13 14:29:12 +0000
commit21671b558cfd8d90647f40a8594fd9e6db038768 (patch)
tree5204ff9fd0eb5569165d17423523fa36ca63c267 /encoding.c
parent62c596cb36af5471e65a4774dfe70047055f58b7 (diff)
* enc/make_encdb.h: sort encoding names by original name.
* encoding.c, enc/*.c: define replicas and aliases. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@15025 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'encoding.c')
-rw-r--r--encoding.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/encoding.c b/encoding.c
index d892c8ff51..a7a62e3bb3 100644
--- a/encoding.c
+++ b/encoding.c
@@ -1087,10 +1087,13 @@ Init_Encoding(void)
rb_define_singleton_method(rb_cEncoding, "default_external", get_default_external, 0);
rb_define_singleton_method(rb_cEncoding, "locale_charmap", rb_locale_charmap, 0);
+ enc_init_db();
+
/* dummy for unsupported, statefull encoding */
rb_define_dummy_encoding("ISO-2022-JP");
-
- enc_init_db();
+ rb_enc_alias("ISO2022-JP", "ISO-2022-JP");
+ rb_define_dummy_encoding("ISO-2022-JP-2");
+ rb_enc_alias("ISO2022-JP-2", "ISO-2022-JP-2");
}
/* locale insensitive functions */