mno2
Haskell 趣學指南

Updated 2 years ago

murphy meng (@murphymeng) started discussion #7

3 years ago · 0 comments

Open

先不去深究 deriving(派生),可以先这样理解:若在 data 声明的后面加上 deriving (Show),那 Haskell 就会自动将该型别至于 Show 型别类之中。好了,由于值构造子是个函数,因此我们可以拿它交给 map,拿它不全调用,以及普通函数能做的一切。

Build Our Own Type and Typeclass (Edit this file)

值构造子?名气咋那么奇怪

No description provided.

No comments on this discussion.


to join this conversation on GitBook. Already have an account? Sign in to comment
Notifications

You’re not receiving notifications from this thread.


1 participant