[英]ghc-mod fails to install
我剛剛在虛擬機上安裝了Arch Linux並安裝了GHC(7.6.1),而cabal-install是版本1.16.0-2
我正在嘗試獲得haskell編碼的環境設置,包括ghcmod-vim插件,當然這需要ghc-mod。
運行cabal install ghc-mod會產生一些錯誤
Gap.hs:81:19:
Couldn't match expected type `PprStyle -> String' with `[Char]'
Expected type: String
Actual type: PprStyle -> String
Probable cause: `renderWithStyle' is applied to too few arguments
In the expression: renderWithStyle d stl
In an equation for `renderMsg':
renderMsg d stl = renderWithStyle d stl
Gap.hs:81:35:
Couldn't match expected type `DynFlags' with actual type `SDoc'
In the first argument of `renderWithStyle', namely `d'
In the expression: renderWithStyle d stl
In an equation for `renderMsg':
renderMsg d stl = renderWithStyle d stl
Gap.hs:81:37:
Couldn't match type `SDoc' with `SDoc'
In the second argument of `renderWithStyle', namely `stl'
In the expression: renderWithStyle d stl
In an equation for `renderMsg':
renderMsg d stl = renderWithStyle d stl
Gap.hs:114:28:
Couldn't match type `Module' with `ModuleName'
Expected type: ModSummary -> ModuleName
Actual type: ModSummary -> Module
In the second argument of `(.)', namely `ms_mod'
In the first argument of `map', namely `(IIModule . ms_mod)'
In the first argument of `(<$>)', namely `map (IIModule . ms_mod)'
我真的不明白這些編譯器錯誤是如何發生的,因為ghc-mod 1.11.0似乎已經在6月份被用於Hackage,而我對類似問題的搜索卻沒有發現。
如何解決這個問題的想法和解決方案?
您可能需要查看https://github.com/kazu-yamamoto/ghc-mod 。 最新的提交稱為“GHC 7.6.1兼容性”,因此該版本可能會解決您的問題。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.