
#12007: Pattern families regression -------------------------------------+------------------------------------- Reporter: MikeIzbicki | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 7.10.3 Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: None/Unknown Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- The following code compiles fine for me in GHC 7.10.1, but fails in GHC 8.1.20160502 {{{ {-# LANGUAGE PatternSynonyms #-} {-# LANGUAGE ViewPatterns #-} data Foo a = Foo a a pattern A a1 a2 = Foo a1 a2 pattern B a1 a2 = A a1 a2 }}} The problem is the nested pattern. Compiling gives: {{{ [1 of 1] Compiling Main ( Bug1.hs, interpreted ) ghc-stage2: panic! (the 'impossible' happened) (GHC version 8.1.20160502 for x86_64-unknown-linux): kindPrimRep.go rep_a85f Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug }}} -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12007 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler