我已经定义了两个模块的类型和两个模块 module type FOO = sig type e end
module type BAR = sig type t end
module Foo : FOO = struct type e = int end
module Bar : BAR = struct type t = int end
当放松类型检查然后我定义一个算符作为 modu
我在写一个使用Data.Vector的Haskell函数库。我成功地编写了库函数,但我不知道如何给它添加签名。下面是说明问题的一个简单的例子:
import qualified Data.Vector.Generic as V
-- zip two vectors and return first element as a tuple
test :: (V.Vector v a, Fra