Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我在 Windows 7 中运行 GHCI 6.4。我不知道将 .hs 文件添加到 .\ghc\ 目录的哪个子目录。每次我尝试使用 :l 时,它都会告诉我找不到该文件。有没有其他人遇到过这个问题?
编辑:谢谢你的回答。这两个看起来都可以工作,但我最终按照教授的建议使用了“:cd”命令。
您可以使用 将目录 PATH 添加到搜索路径:set -iPATH。之后,您可以加载该目录中的文件。
:set -iPATH
我只使用了一点 GHCi,但我总是能够毫无问题地做:l D:\Documents\Haskell\myscript.hs。
:l D:\Documents\Haskell\myscript.hs