[Haskell-cafe] GHC type error pretty printing

Christopher Done chrisdone at gmail.com
Thu Jul 26 19:42:40 CEST 2012


Is it me or is this output not right? The \ syntax doesn't indicate a newline.

chris at midnight:~$ ghci
GHCi, version 7.4.2: http://www.haskell.org/ghc/  :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Prelude> "abc\n123" :: ()

<interactive>:2:1:
    Couldn't match expected type `()' with actual type `[Char]'
    In the expression:
        "abc\
        \123" ::
          ()
    In an equation for `it':
        it
          = "abc\
            \123" ::
              ()



More information about the Haskell-Cafe mailing list