Unable to parse integer-gmp's Cabal file
integer-gmp version 1.0.1.0 has this line in its Cabal file: build-depends: ghc-prim ^>= 0.5.1.0
That uses the new caret constraint syntax. That syntax was introduced by Cabal 2 a few months ago in July/August. Attempting to build integer-gmp with a slightly older version of Cabal, like 1.24.2.0, or with the latest released version of Stack (1.5.1) fails with this error:
Unable to parse cabal file for integer-gmp-1.0.1.0: NoParse "build-depends" 58
This was reported on Stack's issue tracker and on Reddit:
- https://github.com/commercialhaskell/stack/issues/3624
- https://www.reddit.com/r/haskell/comments/7hs20y/how_to_fix_stack_unable_to_parse_cabal_file/
I was not able to find an issue tracker for integer-gmp. Someone suggested that I open an issue here instead.
I can see how this isn't a bug per se because integer-gmp's Cabal file specifies cabal-version: 2.0
. Nevertheless, it's frustrating that a core library is using a bleeding edge feature for basically no reason. It would be nice if integer-gmp used the more typical cabal-version: >= 1.10
and specified its dependency as build-depends: ghc-prim >= 0.5.1 && <0.6
, without the caret operator.
Trac metadata
Trac field | Value |
---|---|
Version | 8.2.2 |
Type | Bug |
TypeOfFailure | CompileTimeCrash |
Priority | normal |
Resolution | Unresolved |
Component | Core Libraries |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |