[Haskell-cafe] gbp sign showing as unknown character by GHC

Brandon S. Allbery KF8NH allbery at ece.cmu.edu
Thu Aug 20 07:58:29 EDT 2009

On Aug 20, 2009, at 05:07 , Ketil Malde wrote:
>    % ghci -e 'map Data.Char.ord "饁"'
>    <interactive>:1:21:
>        lexical error in string/character literal at character '\129'
> but again:
>    % ghci -e 'map Data.Char.ord "£"'
>    [194,163]
> So GHCi used interactively translates input from the terminal's UTF-8,
> but outputs truncates output to eight bits.  Executing a string with
> -e, it appears to read byte for byte (which I think was the original
> behavior at some point).

Makes sense; absent utf8-string, System.Environment.getArgs only groks  

brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery at kf8nh.com
system administrator [openafs,heimdal,too many hats] allbery at ece.cmu.edu
electrical and computer engineering, carnegie mellon university    KF8NH

-------------- next part --------------
A non-text attachment was scrubbed...
Name: PGP.sig
Type: application/pgp-signature
Size: 195 bytes
Desc: This is a digitally signed message part
Url : http://www.haskell.org/pipermail/haskell-cafe/attachments/20090820/8864022a/PGP.bin

More information about the Haskell-Cafe mailing list