[GHC] #4220: EmptyDataDecls + DeriveFunctor == Panic!
GHC
cvs-ghc at haskell.org
Sat Jul 24 23:40:45 EDT 2010
#4220: EmptyDataDecls + DeriveFunctor == Panic!
---------------------------------+------------------------------------------
Reporter: conal | Owner:
Type: bug | Status: new
Priority: normal | Component: Compiler
Version: 6.12.1 | Keywords:
Os: Unknown/Multiple | Testcase:
Architecture: Unknown/Multiple | Failure: Compile-time crash
---------------------------------+------------------------------------------
Comment(by conal):
The following explicit instance works fine, though it's too bad we have to
make the error case explicit, since Void can be covered exhaustively with
no clauses.
{{{
instance Functor Void where
fmap _ = error "Void fmap: no void value" -- so ghc won't complain
}}}
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/4220#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list