[GHC] #11806: GHC does not warn for mistakenly empty case

GHC ghc-devs at haskell.org
Sat Apr 9 21:47:55 UTC 2016


#11806: GHC does not warn for mistakenly empty case
-------------------------------------+-------------------------------------
        Reporter:  dfeuer            |                Owner:
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Compiler          |              Version:  7.10.3
      Resolution:                    |             Keywords:
                                     |  PatternMatchWarnings
Operating System:  Unknown/Multiple  |         Architecture:
 Type of failure:  GHC accepts       |  Unknown/Multiple
  invalid program                    |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:  #10746, #7669,    |  Differential Rev(s):
  #11390                             |
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by simonpj):

 Indeed. Another way to see it is via my examples in comment:1. It is
 extremely unexpected that removing one alternative from an exhaustive
 Boolean `case` would yield a warning, but removing both alternatives does
 not.

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11806#comment:7>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list