Re: [Haskell-cafe] putStrLn "ß"

anderson leo fireman119 at gmail.com
Mon Aug 16 20:22:45 EDT 2010


I've tested haskell on CJK system. For CJK characters, the IO can work great
on file, but awfully on console. I think it is the matter from Winodws.
We can not set utf8 on Windows like linux, instead of that they use code
page. It looks that greek characters doesnot support on your system. You
shall turn on the support in Console Panel/Regional and Language Options.
Sorry for my english, it's not great.

On Tue, Aug 17, 2010 at 2:57 AM, Pepe Gallardo <pepe.haskell at gmail.com>wrote:

> Using the latest version (WinGHCi 1.0.6) and GHCi 6.12.3, I get:
>
> *
>
> Prelude>
> * putStrLn "ß"
>
> ß
> *
>
> Prelude>
> * print "ß"
>
> "\223"
> *
>
> Prelude>
> *
> putStr "αγδ"
>
> *** Exception: <stdout>: hPutChar: invalid argument (character is not in
> the code page)
>
> and this is consistent with output I get when using GHCi on a console on
> Windows.
>
>
>
> Cheers,
> Pepe
>
> 2010/8/13 Henk-Jan van Tuyl <hjgtuyl at chello.nl>
>
>
>> L.S.,
>>
>> When I try
>>  putStrLn "ß"
>> (Eszett (sharp S)) in WinGhci, the interpreter seems to have disappeared;
>> ctrl-C gives the message "Interrupted" in a separate window, but no new
>> prompt. When I start GHCi in a shell, the interpreter displays:
>>  Prelude> print "ß"
>>  "\223"
>>
>> Is this a known issue?
>>
>> Other experiments with WinGhci:
>>  >print "αγδ"
>>  "a?d"
>> (Trying to print alpha, gamma, delta.)
>>
>>  >print "β"
>> (Trying to print beta) interpreter hangs again.
>>
>> Details:
>>  - WinGhci 1.0.2
>>  - GHCi, version 6.12.3
>>  - Windows XP
>>
>> Regards,
>> Henk-Jan van Tuyl
>>
>>
>> --
>> http://Van.Tuyl.eu/ <http://van.tuyl.eu/>
>> http://members.chello.nl/hjgtuyl/tourdemonad.html
>> --
>> _______________________________________________
>> Haskell-Cafe mailing list
>> Haskell-Cafe at haskell.org
>> http://www.haskell.org/mailman/listinfo/haskell-cafe
>>
>
>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://www.haskell.org/mailman/listinfo/haskell-cafe
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20100816/903347ed/attachment.html


More information about the Haskell-Cafe mailing list