One code work from runghc, but I can not compile same one with ghc command. Why?
Below is my minimal code and environment:
https://gist.github.com/1588756
Works well:
$ runghc cat.hs
Can not compile:
$ ghc cat.hs -o cat
Macbook air, max os x snow leopard
The
.csextension shown in your paste is wrong;1 rename the file tocat.hsand it’ll work fine.This error message:
occurs when you pass a file GHC doesn’t know how to handle; it just passes it on directly to the linker, which then ignores it as it doesn’t know, either. 🙂
1 At least until GHC gets C# support…