私は次のことを試しました:
cabal sandbox init
次に、次の cabal ファイルを作成します。
-- Initial hsource.cabal generated by cabal init. For further
-- documentation, see http://haskell.org/cabal/users-guide/
name: hsource
version: 0.1.0.0
-- synopsis:
-- description:
-- license:
license-file: LICENSE
author: abc
maintainer: abc
-- copyright:
-- category:
build-type: Simple
-- extra-source-files:
cabal-version: >=1.10
executable hsource
main-is: main.hs
other-modules:
-- other-extensions:
build-depends: base >=4.7 && <4.8, csv
hs-source-dirs: src
default-language: Haskell2010
次に、CSV パッケージを次のようにインストールします。
cabal install --only-dependencies
import Text.CSV
試してみるとC-c C-l
、次のエラーが表示されます。
Util/RandomTree.hs:7:8-15: Could not find module ‘Text.CSV’ …
Use -v to see a list of the files searched for.
Compilation failed.
私の質問は、サンドボックスが haskell-mode でサポートされていないのか、それともサンドボックスを機能させるためのいくつかの手順が欠けているのでしょうか?