News for hackers. Stuff that matters.
Re:What developers should know about Unicode and character s... by jrochkind1 on Wednesday November 06, 2013 @07:40AM (#6682359)
> Never assume that the data you’re dealing with is UTF-8 — ASCII appears identical unless you view the hex to see if each character is taking one byte (ASCII) or three (UTF-8).

Um, what? This is just wrong. ascii-equivalent characters only take one byte in UTF-8. Other characters may take two, or three, bytes.

If the author actually viewed text in ascii that, when in UTF-8, had three-bytes per character.... I don't know what they were looking at, but it wasn't UTF-8.

Re:What developers should know about Unicode and character s... by jrochkind1 on Wednesday November 06, 2013 @06:04PM (#6686218)
Also, if the data is ASCII, and includes only legal 7-bit ASCII characters -- it is simultaneously ALSO valid and legal UTF-8. UTF-8 is a superset of ASCII.

I'm not sure this guy understands what he's talking about.