From: Yukihiro Matsumoto Date: 2008-12-18T16:07:56+09:00 Subject: [ruby-core:20630] Re: 1.9 character encoding (was: encoding of symbols) Hi, In message "Re: [ruby-core:20619] Re: 1.9 character encoding (was: encoding of symbols)" on Thu, 18 Dec 2008 08:43:45 +0900, danielcavanagh@aanet.com.au writes: |> Is there any alternative choice that makes sense? | |i think there is an alternative :) in fact, i think it should be the only |option: doing it by character, not byte. if we have a string ("cat" for |example) in two different, incompatible encodings (say latin-1 and ucs4), |they *should* match because they are the *same* thing: "cat" and "cat" | |why should we care how the characters are represented in the computer? |there is already too much trouble caused by all the different encodings in |the world. the encodings should disappear from view and we should only see |the characters, unless we explicitly ask for the byte values I am against trancoding before comparison. The applications models falls into either: * treat single encoding only, say iso-8869-1 (single encoding model) * convert everything Unicode at I/O (universal encoding model) * mix various encoding per strings (multiple encoding model) Most of the applications use the former two, and mix encoding comparison happens only in the last one. So I don't think we need to make comparison more complex than it is now. matz.