[GHC] #14893: GHC hangs while producing error message for incorrect TypeFamilies application
GHC
ghc-devs at haskell.org
Mon Mar 5 21:05:37 UTC 2018
#14893: GHC hangs while producing error message for incorrect TypeFamilies
application
-------------------------------------+-------------------------------------
Reporter: coopercm | Owner: (none)
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 8.2.2
Keywords: | Operating System: Linux
Architecture: | Type of failure: Compile-time
Unknown/Multiple | crash or panic
Test Case: | Blocked By:
Blocking: | Related Tickets:
Differential Rev(s): | Wiki Page:
-------------------------------------+-------------------------------------
Here's a minimally reproducible example:
{{{#!hs
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE MultiParamTypeClasses #-}
module Main where
newtype Token f a = Token { unToken :: f a }
class Class x (f :: * -> *) where
type Meta x f :: *
type Body x f :: *
type Body x f = Token f Meta
main :: IO ()
main = return ()
}}}
This hangs like so
{{{
[2 of 2] Compiling Main ( app/Main.hs, .stack-
work/dist/x86_64-linux/Cabal-2.0.1.0/build/foo-exe/foo-exe-tmp/Main.o )
}}}
I tested on 8.2.2 and 8.0.2 and got the same behavior.
The closest existing bug report I could find was
https://ghc.haskell.org/trac/ghc/ticket/12386.
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14893>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list