cabal 使用 GHC 8.4 安装 djinn-lib?
cabal install djinn-lib with GHC 8.4?
我正在尝试使用 GHC 8.4.1(来自 Ubuntu 16.04 apt-get
)安装 djinn-lib
。
$ cabal install djinn-lib
但是我在 <>
运算符中收到歧义错误,如底部所示。
有人知道如何修复它吗?
我使用的 cabal 版本是:
$ cabal --version
cabal-install version 2.2.0.0
compiled using version 2.2.0.0 of the Cabal library
错误信息是:
$ cabal install djinn-lib
Resolving dependencies...
Configuring djinn-lib-0.0.1.2...
Preprocessing library for djinn-lib-0.0.1.2..
Building library for djinn-lib-0.0.1.2..
[1 of 4] Compiling Djinn.LJTFormula ( src/Djinn/LJTFormula.hs, dist/build/Djinn/LJTFormula.o )
[2 of 4] Compiling Djinn.LJT ( src/Djinn/LJT.hs, dist/build/Djinn/LJT.o )
[3 of 4] Compiling Djinn.HTypes ( src/Djinn/HTypes.hs, dist/build/Djinn/HTypes.o )
src/Djinn/HTypes.hs:242:29: error:
Ambiguous occurrence ‘<>’
It could refer to either ‘Prelude.<>’,
imported from ‘Prelude’ at src/Djinn/HTypes.hs:5:8-19
(and originally defined in ‘GHC.Base’)
or ‘Text.PrettyPrint.HughesPJ.<>’,
imported from ‘Text.PrettyPrint.HughesPJ’ at src/Djinn/HTypes.hs:36:67-70
|
242 | ppPat _ (HPAt s p) = text s <> text "@" <> ppPat 10 p
| ^^
src/Djinn/HTypes.hs:242:41: error:
Ambiguous occurrence ‘<>’
It could refer to either ‘Prelude.<>’,
imported from ‘Prelude’ at src/Djinn/HTypes.hs:5:8-19
(and originally defined in ‘GHC.Base’)
or ‘Text.PrettyPrint.HughesPJ.<>’,
imported from ‘Text.PrettyPrint.HughesPJ’ at src/Djinn/HTypes.hs:36:67-70
|
242 | ppPat _ (HPAt s p) = text s <> text "@" <> ppPat 10 p
| ^^
Failed to install djinn-lib-0.0.1.2
cabal: Error: some packages failed to install:
djinn-lib-0.0.1.2-72XYG7inpNR6A7gk4acAK4 failed during the building phase. The
exception was:
ExitFailure 1
标识符 <>
已添加到序曲中,它与 HughesPJ 中现有的标识符冲突。您可以将行 import Prelude hiding((<>>))
添加到相关文件的导入部分以解决此问题...
我正在尝试使用 GHC 8.4.1(来自 Ubuntu 16.04 apt-get
)安装 djinn-lib
。
$ cabal install djinn-lib
但是我在 <>
运算符中收到歧义错误,如底部所示。
有人知道如何修复它吗?
我使用的 cabal 版本是:
$ cabal --version
cabal-install version 2.2.0.0
compiled using version 2.2.0.0 of the Cabal library
错误信息是:
$ cabal install djinn-lib
Resolving dependencies...
Configuring djinn-lib-0.0.1.2...
Preprocessing library for djinn-lib-0.0.1.2..
Building library for djinn-lib-0.0.1.2..
[1 of 4] Compiling Djinn.LJTFormula ( src/Djinn/LJTFormula.hs, dist/build/Djinn/LJTFormula.o )
[2 of 4] Compiling Djinn.LJT ( src/Djinn/LJT.hs, dist/build/Djinn/LJT.o )
[3 of 4] Compiling Djinn.HTypes ( src/Djinn/HTypes.hs, dist/build/Djinn/HTypes.o )
src/Djinn/HTypes.hs:242:29: error:
Ambiguous occurrence ‘<>’
It could refer to either ‘Prelude.<>’,
imported from ‘Prelude’ at src/Djinn/HTypes.hs:5:8-19
(and originally defined in ‘GHC.Base’)
or ‘Text.PrettyPrint.HughesPJ.<>’,
imported from ‘Text.PrettyPrint.HughesPJ’ at src/Djinn/HTypes.hs:36:67-70
|
242 | ppPat _ (HPAt s p) = text s <> text "@" <> ppPat 10 p
| ^^
src/Djinn/HTypes.hs:242:41: error:
Ambiguous occurrence ‘<>’
It could refer to either ‘Prelude.<>’,
imported from ‘Prelude’ at src/Djinn/HTypes.hs:5:8-19
(and originally defined in ‘GHC.Base’)
or ‘Text.PrettyPrint.HughesPJ.<>’,
imported from ‘Text.PrettyPrint.HughesPJ’ at src/Djinn/HTypes.hs:36:67-70
|
242 | ppPat _ (HPAt s p) = text s <> text "@" <> ppPat 10 p
| ^^
Failed to install djinn-lib-0.0.1.2
cabal: Error: some packages failed to install:
djinn-lib-0.0.1.2-72XYG7inpNR6A7gk4acAK4 failed during the building phase. The
exception was:
ExitFailure 1
标识符 <>
已添加到序曲中,它与 HughesPJ 中现有的标识符冲突。您可以将行 import Prelude hiding((<>>))
添加到相关文件的导入部分以解决此问题...