-
Notifications
You must be signed in to change notification settings - Fork 19
Prepare for 2.0 release #22
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@paf31 any comments here? |
@@ -53,7 +40,7 @@ instance applicativeFirst :: Applicative First where | |||
pure = First <<< pure | |||
|
|||
instance bindFirst :: Bind First where | |||
bind (First x) f = First (bind x (runFirst <<< f)) | |||
bind (First x) f = First (x >>= \y -> case f y of First ma -> ma) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this should be derivable.
@@ -53,7 +40,7 @@ instance applicativeLast :: Applicative Last where | |||
pure = Last <<< pure | |||
|
|||
instance bindLast :: Bind Last where | |||
bind (Last x) f = Last (bind x (runLast <<< f)) | |||
bind (Last x) f = Last (x >>= \y -> case f y of Last ma -> ma) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same
Sorry didn't see this one. Nothing blocking, just noticed a couple of possibly-derivable instances. Thanks! |
Nice, thanks for the reminder - they're almost entirely derivable 😄 |
They should be marginally faster too, which is good. |
No description provided.