ruby-changes:56898
From: Nobuyoshi <ko1@a...>
Date: Sat, 10 Aug 2019 01:24:39 +0900 (JST)
Subject: [ruby-changes:56898] Nobuyoshi Nakada: 88db6fa479 (master): Use ENC_REPLICATE to copy an encoding
https://git.ruby-lang.org/ruby.git/commit/?id=88db6fa479 From 88db6fa4793da3724c0128e53cfe1abead1774f8 Mon Sep 17 00:00:00 2001 From: Nobuyoshi Nakada <nobu@r...> Date: Sat, 10 Aug 2019 01:04:39 +0900 Subject: Use ENC_REPLICATE to copy an encoding diff --git a/enc/gb2312.c b/enc/gb2312.c index 6fc1573..7756534 100644 --- a/enc/gb2312.c +++ b/enc/gb2312.c @@ -1,13 +1,6 @@ https://github.com/ruby/ruby/blob/trunk/enc/gb2312.c#L1 -#include <ruby/ruby.h> -#include <ruby/encoding.h> #include "regenc.h" -void -Init_gb2312(void) -{ - rb_enc_register("GB2312", rb_enc_find("EUC-KR")); -} - +ENC_REPLICATE("GB2312", "EUC-KR") ENC_ALIAS("EUC-CN", "GB2312") ENC_ALIAS("eucCN", "GB2312") ENC_REPLICATE("GB12345", "GB2312") -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/