
#12411: GHC panic on TypeApplications + TemplateHaskell -------------------------------------+------------------------------------- Reporter: Iceland_jack | Owner: Type: bug | Status: new Priority: normal | Milestone: Component: Compiler | Version: 8.0.1 Resolution: | Keywords: | TypeApplications, TemplateHaskell Operating System: Unknown/Multiple | Architecture: Type of failure: Compile-time | Unknown/Multiple crash | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by Shayan-Najd): As RyanGlScott pointed out in #12584, essentially the problem is with patterns (here "as" pattern) being accepted (temporarily in the renamer) as expressions. Here is a minimal way to trigger the same error: {{{ GHCi, version 8.0.1: http://www.haskell.org/ghc/ :? for help Prelude> :set -XTemplateHaskell Prelude> pure @Q [];return () ghc: panic! (the 'impossible' happened) (GHC version 8.0.1 for x86_64-unknown-linux): tcMonoExpr _ Please report this as a GHC bug: http://www.haskell.org/ghc/reportabug }}} -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/12411#comment:4 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler