Learn you a Haskell for Great Good 中的错字?
Typo in Learn you a Haskell for Great Good?
在Type Synonyms我们读到
Just like we can partially apply functions to get new functions, we can partially apply type parameters and get new type constructors from them.
如何将参数应用于其他东西?我觉得其实应该是
Just like we can partially apply functions to get new functions, we can partially apply type constructor (giving them less type parameters then they expect) and get new type constructors from them.
你同意吗?
作者好像用apply来表示"the function to the parameters"和"the parameters to the function"。
往下看
we'll partially apply Either by feeding it only one parameter
凡是前者的意思,
以及
Let's apply the type parameter to Maybe and see what the kind of that type is.
ghci> :k Maybe Int
这里的意思是后者。
在Type Synonyms我们读到
Just like we can partially apply functions to get new functions, we can partially apply type parameters and get new type constructors from them.
如何将参数应用于其他东西?我觉得其实应该是
Just like we can partially apply functions to get new functions, we can partially apply type constructor (giving them less type parameters then they expect) and get new type constructors from them.
你同意吗?
作者好像用apply来表示"the function to the parameters"和"the parameters to the function"。
往下看
we'll partially apply Either by feeding it only one parameter
凡是前者的意思, 以及
Let's apply the type parameter to Maybe and see what the kind of that type is.
ghci> :k Maybe Int
这里的意思是后者。