I가 명령 줄에 잘 작동합니다 다음 코드를이유는 하스켈에서 내 코드가 아닌 파일에서 명령 줄에서 작동하지
ghci> [let square x = x * x in (square 5, square 3, square 2)]
[(25,9,4)]
을하지만 난 파일에 있고, 그것을 컴파일 할 때 작동하지 않고 오류가 발생합니다.
[1 of 1] Compiling Main (baby.hs, interpreted)
baby.hs:62:1:
Parse error: naked expression at top level
Perhaps you intended to use TemplateHaskell
Failed, modules loaded: none.