更新:澄清这是在 Mac OS X 上
我在 Mac OS X 上使用 Emacs Prelude (它使用haskell-mode),我已经创建了一个带有stack new hello
.
它生成的项目是这样的:
- 你好:
- 执照
- 安装程序.hs
- 你好,阴谋集团
- 堆栈.cabal
- 应用程序:
- 主文件
- 源代码:
- 库文件
- 测试:
- 规范
如果我在 Emacs 中打开Main.hs,它会显示:
module Main where
import Lib
main :: IO ()
main = someFunc
但是Lib被强调为一个错误,并且将我的插入符号放在那里显示了这一点:
Could not find module 'Lib'
Use -v to see a list of the files searched for.
你如何让 Emacs haskell-mode 在其他 hs-source-dirs 中查找模块?