Undefined symbol during linking
On OSX, using GHC 7.6.3 and the package recursion-schemes 3.0.0.2, the following code causes the compiler to emit an error about undefined symbols.
Code:
import Data.Functor.Foldable
x = project 1 :: Integer
main = x `seq` return ()
Error:
λ ~/ ghc test.hs
Linking test ...
Undefined symbols for architecture x86_64:
"_Main_x_closure", referenced from:
_Main_main_info in test.o
_Main_main_srt in test.o
ld: symbol(s) not found for architecture x86_64
collect2: ld returned 1 exit status
Trac metadata
Trac field | Value |
---|---|
Version | 7.6.3 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | Compiler |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | Unknown/Multiple |
Architecture | Unknown/Multiple |