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

Colin Paul Adams colin at colina.demon.co.uk
Thu Aug 20 02:13:28 EDT 2009


>>>>> "Judah" == Judah Jacobson <judah.jacobson at gmail.com> writes:

    Judah> On Wed, Aug 19, 2009 at 10:31 AM, Iain Barnett<iainspeed at gmail.com> wrote:
    >> Quick question: I've tested this in a couple of different
    >> terminals (roxterm and xterm), so I'm fairly sure it's GHC
    >> that's the problem. Have I missed a setting?  GHCi, version
    >> 6.10.4
    Prelude> putStrLn "£"
    >> � Hugs98 200609-3
    Hugs> putStrLn "£"
    >> £
    >> 

ghc-6.10.4 and earlier don't automatically encode/decode Unicode
    Judah> characters.  So on terminals which don't use the latin-1
    Judah> encoding, you need to do the conversion explicitly with a
    Judah> separate package such as utf8-string, iconv or text-icu.

I don't understand where latin-1 comes into this. String is supposed
to be a list of Unicode characters.
-- 
Colin Adams
Preston Lancashire


More information about the Haskell-Cafe mailing list