First, I created a new workspace:
stack new xxxx
stack init
stack build
then
cd xxx\app
stack ghci
import Data.Map
I can import other modules like Data.Char
and Data.List
, but I can't import Data.Map
. GHCi told me:
Could not find module 'Data.Map'
It is a member of the hidden package '[email protected]'.`
xxxx.cabal
, add a library/executable section, and addcontainers
in thebuild-depends
section. See this answer. – Navaho