
13 Aug
2010
13 Aug
'10
11:52 a.m.
On Friday 13 August 2010 17:27:32, Sean Leather wrote:
Which one do you use for strings in HTML or XML in which UTF-8 has become the commonly accepted standard encoding? It's text, not binary, so I should choose Data.Text. But isn't there a performance penalty for translating from Data.Text's internal 16-bit encoding to UTF-8?
Yes there is. Whether using String, Data.Text or Data.ByteString + Data.ByteString.UTF8 is the best choice depends on what you do. Test and then decide.