-
Notifications
You must be signed in to change notification settings - Fork 375
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
derivations do not make certain methods optional #134
Conversation
@@ -30,9 +30,7 @@ An algebra is a set of values, a set of operators that it is closed | |||
under and some laws it must obey. | |||
|
|||
Each Fantasy Land algebra is a separate specification. An algebra may | |||
have dependencies on other algebras which must be implemented. An | |||
algebra may also state other algebra methods which do not need to be | |||
implemented and how they can be derived from new methods. |
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 didn't realize this sentence existed in the spec. That makes most of what I said in #132 questionable.
While we are at it, maybe we should add something like:
To clarify that matter once and for all. See Gitter discussion: https://gitter.im/fantasyland/fantasy-land?at=570a28a4c65c9a6f7f284c1c |
I also don't quite understand why they are here. I think |
That may be the case, but the wording can surely be improved. Currently we state:
Could we remove mention of
|
I like that |
1c2f444
to
2dfa181
Compare
function(m) { return this.chain(f => m.map(f)); } | ||
|
||
If a data type provides a method which *could* be derived, its behaviour must | ||
be equivalent to that of the derivation (or derivations). |
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 added this sentence based on your suggestion, @rpominov.
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.
Great!
The I've reverted the removal of |
We should also move |
I like your idea of replacing it with a law:
|
2dfa181
to
62fb25b
Compare
Derivations of FL methods are relevant to implementers of data types. Derivations of FL methods are irrelevant to implementers of functions which operate on values of these types, since the values must provide the relevant methods.
62fb25b
to
447775f
Compare
Thank you for the feedback, @rpominov. I've made the following changes:
|
I prefer this version of the spec over the current. 👍 |
👍 |
Thanks, @puffnfresh! Can we merge this now? @SimonRichardson? |
Sure, do it On Wed, 15 Jun 2016, 01:34 David Chambers, notifications@github.com wrote:
|
I'm hoping someone with write access will hit the merge button. ;) |
Haha, done! |
Closes #132
Commit message:
I'm not sure how
toArray
andtraverse
fit into the specification.