#3263: Warnings for monadic values not used
---------------------------------+------------------------------------------
Reporter: NeilMitchell | Owner:
Type: feature request | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 6.10.2
Severity: normal | Resolution:
Keywords: | Difficulty: Unknown
Testcase: | Os: Unknown/Multiple
Architecture: Unknown/Multiple |
---------------------------------+------------------------------------------
Changes (by simonpj):
* difficulty: => Unknown
Comment:
Thank you Max. I've had a look. Generally fine. Most of the lines of
code changed are to make the compiler and libraries warning-free. Only a
few (in `DsExpr` actually implement the feature).
IAN: could you commit the patches please?
Once that's done, I have two thoughts
* I found `-fwarn-wrong-do-bind` quite confusing. I believe that (a) it
is on by default, but (b) any program that warns because of `-fwarn-wrong-
do-bind` will '''also''' warn because of `-fwarn-unused-do-bind`, if the
latter flag is on. So we really only want one or the other, never both.
Is that right?
* The formatting of the error messages is very very wide, much more so
than any other GHC error. Better reformat please.
* I found the error message for `-fwarn-wrong-do-bind` pretty confusing.
Since they are so closely related can we give them closely related
messages, like:
{{{
A do-notation statement discarded a result of type <type>
Suppress this warning by saying "_ <- blah", or flag <flag>
}}}
where <type> and <flag> are appropriately substituted. That seems much
more direct to me.
Simon
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/3263#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs