【发布时间】:2012-05-07 16:26:17
【问题描述】:
升级到 ghc 7.4 后,我不得不从各种脚本中删除 import System,但这使得它们与 GHC 6.0 中的 runhaskell 不兼容,后者仍在许多环境中使用。
有没有办法同时支持这两个版本?
当我在 ghc 7.4 中使用 import System 运行脚本时收到的消息:
% ./script.hs
Could not find module `System'
It is a member of the hidden package `haskell98-2.0.0.1'.
Use -v to see a list of the files searched for.
【问题讨论】:
-
为什么还在使用 GHC 6.0?它是从 2003 年开始的。
-
我会说,
{-#Language CPP#-}和 the usual manipulations,但我认为 GHC-6.0 不支持这种写法:) 请注意,即使是最近的拥抱也支持分层命名方案。
标签: haskell