On 31 July 2012 21:01, Richard Cobbe <co...@ccs.neu.edu> wrote: > On Mon, Jul 30, 2012 at 11:45:38PM +1000, Ivan Lazar Miljenovic wrote: >> On 30 July 2012 04:04, Richard Cobbe <co...@ccs.neu.edu> wrote: >> > I'm working on an application that involves processing a lot of Unicode >> > data, and I'm finding the built-in Show implementation for Char to be >> > really inconvenient. Specifically, it renders all characters at U+0080 and >> > above with decimal escapes: >> > >> > Prelude> '\x80' >> > '\128' >> > >> > This is annoying because all of the Unicode charts give the code points in >> > hex, and indeed the charts are split into different PDFs at numbers that >> > are nice and round in hex but not in decimal. So in order to figure out >> > which character I'm looking at, I have to convert back to hex and then look >> > it up in the charts. >> >> Can I ask what you're doing here? Are you printing individual >> characters or entire chunks of text? > > Mostly, I'm working with expressions of type String, rather than Text;
Any particular reason why? Using Text will probably solve your problem and give you a performance improvement at the same time. -- Ivan Lazar Miljenovic ivan.miljeno...@gmail.com http://IvanMiljenovic.wordpress.com _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe