[Haskell-cafe] Help debugging code broken after upgrading debian to GHC 6.12: "invalid argument"

Brandon S. Allbery KF8NH allbery at ece.cmu.edu
Fri May 14 20:53:43 EDT 2010


On May 14, 2010, at 20:24 , Brandon Simmons wrote:
> The other baffling thing is this: if the debugging line 426 is
> uncommented, then even running:
>
>    $> runghc Befunge.hs --quiet mycology.b98
>
> ...will fail. But all we're doing is a call to `putStr`! Why would
> that trigger an error?! Maybe there was a bug in my code that was


GHC 6.12's runtime handles input and output encoding, instead of  
simply truncating Chars; my guess is it's locale-related.  And sure  
enough, I see several non-ASCII characters in mycology.b98 which are  
likely to do the wrong thing if the runtime doesn't know which  
character set to use.

-- 
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/20100514/ea44907a/PGP.bin


More information about the Haskell-Cafe mailing list