Hi All,
I have a problem loading any source file into ghci. I get lots of
"Not in scope" error messages. I am just cutting and pasting these examples from various tutorials
such as
so the syntax should be correct.
See the example below. I must be missing something very fundamental!
Bye
Rob
localhost: ghci --version
The Glorious Glasgow Haskell Compilation System, version 7.8.4
localhost: pwd
/home/robd/course
localhost: cat t1.hs
main = print (fac 20)
fac 0 = 1
fac n = n * fac (n-1)
localhost: ghci
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
[ 1 of 28] Compiling Course.Core ( src/Course/Core.hs, interpreted )
.
[28 of 28] Compiling Course ( src/Course.hs, interpreted )
>> :load t1
[1 of 1] Compiling Main ( t1.hs, interpreted )
t1.hs:1:8: Not in scope: `print'
t1.hs:1:19: Not in scope: `fromInteger'
t1.hs:3:5: Not in scope: `fromInteger'
t1.hs:3:5: Not in scope: `=='
t1.hs:3:9: Not in scope: `fromInteger'
t1.hs:4:11: Not in scope: `*'
t1.hs:4:19: Not in scope: `-'
t1.hs:4:20: Not in scope: `fromInteger'
Failed, modules loaded: none.
>>