[GHC] #15517: -O0 and pattern synonyms triggers panic in trimJoinCont

GHC ghc-devs at haskell.org
Tue Aug 14 23:47:19 UTC 2018


#15517: -O0 and pattern synonyms triggers panic in trimJoinCont
-------------------------------------+-------------------------------------
        Reporter:  sjakobi           |                Owner:  (none)
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:  8.6.1
       Component:  Compiler          |              Version:  8.4.3
      Resolution:                    |             Keywords:
Operating System:  Unknown/Multiple  |         Architecture:
 Type of failure:  Compile-time      |  Unknown/Multiple
  crash or panic                     |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by monoidal):

 I reduced to:

 {{{
 {-# LANGUAGE PatternSynonyms #-}
 module T15517 where

 data Nat = Z | S Nat

 pattern Zpat = Z

 class Family ki where
   sfrom :: Nat -> () -> ki

 instance Family Bool where
   sfrom Zpat  = \_ -> False
   sfrom (S Z) = \_ -> False
 }}}

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


More information about the ghc-tickets mailing list