Could not find module `Data.Map'
It is a member of the hidden package `containers-0.5.0.0'.
Perhaps you need to add `containers' to the build-depends in your .cabal file.
Use -v to see a list of the files searched for.
Failed, modules loaded: none.
But when I type Data.<CTRL-SPACE> I get a list from which I could choose Data.Map. So, what fails with my setup? (In the WinGHCi the module could be loaded without any problems.)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
GHCi puts all packages in scope, which is not the case of a Cabal built project. Since EclipseFP is using Cabal to know which packages your project references, this is normal. The error above is because EclipseFP gives you all possible imports, but you don't have the corresponding package in your cabal file. Just choose quick fix on the error, and choose add containers to cabal file, EclipseFP will do the modification for you and your code will compile.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
GHCi puts all packages in scope, which is not the case of a Cabal built project. Since EclipseFP is using Cabal to know which packages your project references, this is normal. The error above is because EclipseFP gives you all possible imports, but you don't have the corresponding package in your cabal file. Just choose quick fix on the error, and choose add containers to cabal file, EclipseFP will do the modification for you and your code will compile.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
When I type just the line
import Data.Map
then I get the following error:
But when I type Data.<CTRL-SPACE> I get a list from which I could choose Data.Map. So, what fails with my setup? (In the WinGHCi the module could be loaded without any problems.)
GHCi puts all packages in scope, which is not the case of a Cabal built project. Since EclipseFP is using Cabal to know which packages your project references, this is normal. The error above is because EclipseFP gives you all possible imports, but you don't have the corresponding package in your cabal file. Just choose quick fix on the error, and choose add containers to cabal file, EclipseFP will do the modification for you and your code will compile.
GHCi puts all packages in scope, which is not the case of a Cabal built project. Since EclipseFP is using Cabal to know which packages your project references, this is normal. The error above is because EclipseFP gives you all possible imports, but you don't have the corresponding package in your cabal file. Just choose quick fix on the error, and choose add containers to cabal file, EclipseFP will do the modification for you and your code will compile.
Thx. this solved the problem.