ruby-changes:43300
From: duerst <ko1@a...>
Date: Sat, 11 Jun 2016 09:58:53 +0900 (JST)
Subject: [ruby-changes:43300] duerst:r55374 (trunk): * enc/iso_8859_1.c: Revert to older version of code.
duerst 2016-06-11 09:58:49 +0900 (Sat, 11 Jun 2016) New Revision: 55374 https://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=revision&revision=55374 Log: * enc/iso_8859_1.c: Revert to older version of code. Modified files: trunk/ChangeLog trunk/enc/iso_8859_1.c Index: enc/iso_8859_1.c =================================================================== --- enc/iso_8859_1.c (revision 55373) +++ enc/iso_8859_1.c (revision 55374) @@ -260,7 +260,7 @@ case_map (OnigCaseFoldType* flagP, const https://github.com/ruby/ruby/blob/trunk/enc/iso_8859_1.c#L260 const OnigUChar* end, OnigUChar* to, OnigUChar* to_end, const struct OnigEncodingTypeST* enc) { - OnigCodePoint code, lower; + OnigCodePoint code; OnigUChar *to_start = to; OnigCaseFoldType flags = *flagP; @@ -278,10 +278,11 @@ case_map (OnigCaseFoldType* flagP, const https://github.com/ruby/ruby/blob/trunk/enc/iso_8859_1.c#L278 code = 's'; } } - else if ((lower=ONIGENC_ISO_8859_1_TO_LOWER_CASE(code)) != code) - && (flags&ONIGENC_CASE_UPCASE)) { - flags |= ONIGENC_CASE_MODIFIED; - code = lower; + else if (code==0xAA || code==0xBA) ; + else if ((EncISO_8859_1_CtypeTable[code] & BIT_CTYPE_UPPER) + && (flags & (ONIGENC_CASE_DOWNCASE|ONIGENC_CASE_FOLD))) { + flags |= ONIGENC_CASE_MODIFIED; + code += 0x20; } else if ((EncISO_8859_1_CtypeTable[code]&BIT_CTYPE_LOWER) && (flags&ONIGENC_CASE_UPCASE)) { Index: ChangeLog =================================================================== --- ChangeLog (revision 55373) +++ ChangeLog (revision 55374) @@ -1,3 +1,7 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Sat Jun 11 09:58:45 2016 Martin Duerst <duerst@i...> + + * enc/iso_8859_1.c: Revert to older version of code. + Sat Jun 11 09:46:17 2016 Martin Duerst <duerst@i...> * enc/iso_8859_1.c: Implement non-ASCII case mapping. -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/