[Haskell-beginners] HXT: encoding problem

Chaddaï Fouché chaddai.fouche at gmail.com
Mon Sep 29 04:46:08 UTC 2014


On Sun, Sep 28, 2014 at 2:11 PM, Elias Diem <lists at webconect.ch> wrote:

> On 2014-09-28,  Elias Diem wrote:
>
> > I will test it later this day on another computer as well.
>
> I just tested it on another Linux box. And it works!! What
> could be the problem?
>
>
readString is documented as not doing any decoding, so you're dependent on
your readFile doing it right for you, but that depends on your locale !
You could set your IO system input encoding yourself to avoid the problem
but it seems simpler to use "readDocument" provided by Hxt instead since
that'll read the file with your specified input encoding.

-- 
Jedaï
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/beginners/attachments/20140929/95c6265a/attachment.html>


More information about the Beginners mailing list