-
Notifications
You must be signed in to change notification settings - Fork 29
Show Either's "do notation" similarity to nested if-then-else statement #52
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
I think this is probably more suitable for the |
I agree that a more intuitive explanation of what the Bind instance does would be good, but I'm not sure pseudocode is the best way of achieving that; I think prose would probably be preferable. |
The reason that I prefer prose over pseudocode is mostly that not everyone is that familiar with whatever language your pseudocode is based on, and even if they were, they might not be able to work out what e.g. |
Not using pseudo code makes sense. However, I'm not sure how to write that without it being just as confusing. I feel like a visual of some sorts would explain this much better. Is it possible to include images in documentation? |
Also, I explained how the |
Rather than using pseudo-code, I explained it using regular PureScript. I also moved the explanation to the Bind instance. |
This move also uses PureScript to show the code that this notation ultimately produces
I had to force-push this because CI was not pulling in the v0.14.0-rc3 binary |
CI now builds. Harry, this is the same approach you previously approved regarding |
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.
Looks great!
No description provided.