Project

General

Profile

Bug #4340 ยป string.c.gsub.encoding.patch

Set destination string encoding to source string encoding for String#gsub - drbrain (Eric Hodel), 02/02/2011 08:43 AM

View differences:

string.c (working copy)
slen = RSTRING_LEN(str);
cp = sp;
str_enc = STR_ENC_GET(str);
rb_enc_associate(dest, str_enc);
do {
n++;
    (1-1/1)