Re: Reding unicode characters?
On Tue, Mar 11, 2008 at 7:49 AM, James Gray <james@grayproductions.net> wro=
te:
>
> If the code was not character aware, it would have returned a count of
> the bytes in the String (more than six). String#size, for example.
>
>
> > Where are there any unicode characters in your string?
>
> I entered the accented e characters in UTF-8, that's why you see the -
> KU switch to tell Ruby the encoding.
>
> James Edward Gray II
I think this may have been discussed before, but -KU doesn't work for
me on Windows XP. I get an unterminated string error with the
"R=E9sum=E9" UTF-8 encoded string. I can only assume that the parser is
still interpreting the string as one byte per character. Anyone have
any ideas?
Todd
|