在Edward Kmett的演讲中,Lenses,Folds和Traversals,在幻灯片"The Power is the Dot"中,他展示的(.) . (.) . (.)是
(a -> b) -> (c -> d -> e -> a) -> c -> d -> e -> b
我可以通过在GHCI中显示它的类型来看到它.但我也想知道原因.我想了解的另一件事是为什么有在从参数中经常换着花样(.)来(.) . (.)和(.) . (.) . (.):
(.) :: (a -> b) -> (c -> a) -> c -> b
(.) . (.) :: (a -> b) -> (c -> d -> a) -> c -> d -> b
(.) . …Run Code Online (Sandbox Code Playgroud) haskell types type-inference combinators function-composition