Comment on Go enjoy Python3Comments−Sir_Cmpwn11yThe C code there fails if the unicode string includes characters whose width is greater than one octet.−zokier11yWhich is noted right in the post:This treats things as byte-array instead of unicode, thus for unicode test it will end up printing just 車賈滑豈.−rakoo11yWhich is useless then, because the output can't safely be considered a string anymore. I don't really see the point of writing the C "equivalent" and giving it any point when it doesn't even do the right thing.−masklinn11yNone of the snippets comes even remotely close to doing the right thing so it doesn't really matter.
Comments
The C code there fails if the unicode string includes characters whose width is greater than one octet.
Which is noted right in the post:
Which is useless then, because the output can't safely be considered a string anymore. I don't really see the point of writing the C "equivalent" and giving it any point when it doesn't even do the right thing.
None of the snippets comes even remotely close to doing the right thing so it doesn't really matter.