-
Notifications
You must be signed in to change notification settings - Fork 70
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
Document GHC-08838 #543
Document GHC-08838 #543
Conversation
--- | ||
|
||
When using a monadic computation in a do block one should either run it | ||
directly or bind it. If neither is done the monadic computation is never |
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.
directly or bind it. If neither is done the monadic computation is never | |
directly or bind the result of the computation to a variable. If neither is done the monadic computation is never |
|
||
--- |
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.
--- | |
--- |
title: Double return | ||
--- | ||
|
||
In this example, there is a nested return which is not bound. Therefore the computation `return 10` is not used and can be removed. |
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.
In this example, there is a nested return which is not bound. Therefore the computation `return 10` is not used and can be removed. | |
In this example, there is a nested return whose result is not bound to a variable. Therefore the computation `return 10` is not used and can be removed. |
01c2aed
to
2b1d450
Compare
2b1d450
to
52dc88a
Compare
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.
Thanks!
We need a better example here. It seems to be this warning only occurs with nested returns. I tried
which didn't produce that warning