
26 Jul
2007
26 Jul
'07
12:13 a.m.
andrewcoppin:
I don't know if anybody cares, but... Today a wrote some trivial code to decode (not encode) UTF-16.
I believe somebody out there has a UTF-8 decoder, but I needed UTF-16 as it happens. (I didn't bother decoding code points outside the BMP - I'm sure you can figure out why.)
If anybody is interested, I can share the code - but it's pretty minimal...
Perhaps you could polish it up, and provide it in a form suitable for use as a patch to: http://code.haskell.org/utf8-string/ that is, put it in a module: Codec.Binary.UTF16.String and provide the functions: encode :: String -> [Word8] decode :: [Word8] -> String ? And then submit that as a patch to Eric, the utf8 maintainer. -- Don