init.hs the library module has
module init where
data Suite = Clubs | Diamonds | Hearts | Spades deriving (Eq,Ord,Enum,Show)
main.hs, the input module has
module Main where
import init
main = do
print (fromEnum Clubs)
Both modules are in the same directory, and the directory is not part of the path to Kabbalah.
When executed, runhaskell main.hsit throws an error like main.hs:2:8: parse error on input ‘init’.
What is the correct way to import a module into the current working directory without polluting global PATH / CABAL variables?
source
share