https://redmine.ruby-lang.org/https://redmine.ruby-lang.org/favicon.ico?17113305112009-09-05T02:12:36ZRuby Issue Tracking SystemRuby master - Feature #2043: incompatible character encodingshttps://redmine.ruby-lang.org/issues/2043?journal_id=56032009-09-05T02:12:36Znaruse (Yui NARUSE)naruse@airemix.jp
<ul><li><strong>Status</strong> changed from <i>Open</i> to <i>Assigned</i></li><li><strong>Assignee</strong> set to <i>naruse (Yui NARUSE)</i></li></ul><p>=begin<br>
Sorry, what is "possible conversion to ASCII" ?<br>
=end</p> Ruby master - Feature #2043: incompatible character encodingshttps://redmine.ruby-lang.org/issues/2043?journal_id=56572009-09-07T11:26:49Zyugui (Yuki Sonoda)yugui@yugui.jp
<ul><li><strong>Target version</strong> set to <i>3.0</i></li></ul><p>=begin</p>
<p>=end</p> Ruby master - Feature #2043: incompatible character encodingshttps://redmine.ruby-lang.org/issues/2043?journal_id=56782009-09-07T15:12:15Zvo.x (Vit Ondruch)v.ondruch@tiscali.cz
<ul></ul><p>=begin<br>
In following example, just characters from US-ASCII are used and in this case the addition works well.</p>
<p>s = 'abc'<br>
a = s.encode 'cp1250'<br>
b = s.encode 'utf-8'<br>
c = a + b<br>
=end</p> Ruby master - Feature #2043: incompatible character encodingshttps://redmine.ruby-lang.org/issues/2043?journal_id=56792009-09-07T15:33:42Znaruse (Yui NARUSE)naruse@airemix.jp
<ul></ul><p>=begin<br>
Ruby 1.9 doesn't automatic conversion.<br>
ASCII character set is a special<br>
because those characters of ASCII compatible encodings are the same characters.</p>
<p>On Ruby 1.9's view, Unicode is not a superset of Windows-1252.<br>
=end</p> Ruby master - Feature #2043: incompatible character encodingshttps://redmine.ruby-lang.org/issues/2043?journal_id=56802009-09-07T15:39:46Znobu (Nobuyoshi Nakada)nobu@ruby-lang.org
<ul><li><strong>Status</strong> changed from <i>Assigned</i> to <i>Rejected</i></li></ul><p>=begin</p>
<p>=end</p> Ruby master - Feature #2043: incompatible character encodingshttps://redmine.ruby-lang.org/issues/2043?journal_id=56812009-09-07T16:17:39Zvo.x (Vit Ondruch)v.ondruch@tiscali.cz
<ul></ul><p>=begin</p>
<blockquote>
<p>On Ruby 1.9's view, Unicode is not a superset of Windows-1252.</p>
</blockquote>
<p>Is the "Ruby 1.9's view" somewhere described in detail? I still have the feeling that it is just half baked :/<br>
=end</p> Ruby master - Feature #2043: incompatible character encodingshttps://redmine.ruby-lang.org/issues/2043?journal_id=56832009-09-07T17:04:13Znaruse (Yui NARUSE)naruse@airemix.jp
<ul></ul><p>=begin<br>
<a href="http://jp.rubyist.net/magazine/?0025-Ruby19_m17n" class="external">http://jp.rubyist.net/magazine/?0025-Ruby19_m17n</a><br>
<a href="http://yokolet.blogspot.com/2009/07/design-and-implementation-of-ruby-m17n.html" class="external">http://yokolet.blogspot.com/2009/07/design-and-implementation-of-ruby-m17n.html</a><br>
I wrote above but in Japanese, second is its translation.</p>
<p><a href="http://github.com/candlerb/string19/tree/master" class="external">http://github.com/candlerb/string19/tree/master</a><br>
James' and string19 is also well documented.</p>
<p>People in ISO 8859 may think why Unicode is not a super set of Windows-1252.<br>
In Japan, because of lack of standard conversion tables<br>
between Japanese legacy encoding (Shift_JIS, EUC-JP, ISO-2022-JP) and Unicode,<br>
vendors use different tables.<br>
This sad situation made that Unicode is not a simple super set of legacy.<br>
Ruby 1.9 inherits this.</p>
<p>If wide consensus for the standard table was made before Ruby 2.0,<br>
Ruby 2.0 may have automatic conversion (or Unicode comes to be the internal code).<br>
=end</p> Ruby master - Feature #2043: incompatible character encodingshttps://redmine.ruby-lang.org/issues/2043?journal_id=56852009-09-07T22:21:01Zvo.x (Vit Ondruch)v.ondruch@tiscali.cz
<ul></ul><p>=begin<br>
Thank you for the links. It was interesting.</p>
<p>I'm looking forward Ruby 2.0 and their automatic conversions, since writing c = a.encode('utf-8') + b.encode('utf-8') to safely concatenate two strings is not sexy at all.</p>
<p>Vit<br>
=end</p>