gpt4 book ai didi

haskell - 警告 : newtype `CInt' is used in an FFI declaration,

转载 作者:行者123 更新时间:2023-12-02 11:59:35 25 4
gpt4 key购买 nike

使用 ghc 7.4.2 构建 gtk2hs-buildtools 时,我收到以下警告:

c2hs/toplevel/C2HSConfig.hs:110:1:
Warning: newtype `CInt' is used in an FFI declaration,
but its constructor is not in scope.
This will become an error in GHC 7.6.1.
When checking declaration:
foreign import ccall safe "static bitfield_direction" bitfield_direction
:: CInt

即使我有导入Foreign.C.Types(CInt),我也会在 FFI 调用中收到类似的警告。

消除此警告的正确方法是什么?

最佳答案

import Foreign.C.Types(CInt(..))

获取构造函数。

关于haskell - 警告 : newtype `CInt' is used in an FFI declaration,,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11112287/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com