[GHC] #14237: -Wredundant-constraints incorrectly treats all type equality constraints as redundant
GHC
ghc-devs at haskell.org
Fri Sep 15 17:02:41 UTC 2017
#14237: -Wredundant-constraints incorrectly treats all type equality constraints as
redundant
-------------------------------------+-------------------------------------
Reporter: lexi.lambda | Owner: (none)
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 8.2.1
Resolution: | Keywords:
Operating System: Unknown/Multiple | Architecture:
Type of failure: Incorrect | Unknown/Multiple
error/warning at compile-time | Test Case:
Blocked By: | Blocking:
Related Tickets: #12700 | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by lexi.lambda):
I disagree that this is “very similar” to #12700. This is a **regression**
from GHC 8.0, which did not have this problem. The type equality in the
example given in #12700 is arguably redundant, since the program would
compile without it, but the examples I’ve given in this ticket will fail
to compile if the equalities are removed.
When compiling these with `-Wredundant-constraints` in GHC 8.0.2, no
warning is produced. In GHC 8.2.1, a warning ''is'' produced. I’m not sure
why this happens, but it seems like a real step backwards, and it’s much
more severe than #12700.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14237#comment:4>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list