#1999: panic with GADT etc.
----------------------------+-----------------------------------------------
Reporter: jeltsch | Owner:
Type: bug | Status: new
Priority: normal | Milestone: 6.10 branch
Component: Compiler | Version: 6.9
Resolution: | Keywords:
Testcase: T1999, T1999a | Blockedby:
Difficulty: Unknown | Os: Linux
Blocking: | Architecture: x86
Failure: None/Unknown |
----------------------------+-----------------------------------------------
Comment(by japple):
I don't really understand the implications of this yet. In Cheney &
Hinze's [http://ecommons.cornell.edu/handle/1813/5614 "First-Class Phantom
Types"] there is an example that this change might break:
{{{
{-# LANGUAGE GADTs #-}
module Trie where
data Trie k v where
Unit :: Maybe v -> Trie () v
Sum :: Trie k1 v -> Trie k2 v -> Trie (Either k1 k2) v
Prod :: Trie k1 (Trie k2 v) -> Trie (k1,k2) v
merge :: (v->v->v) -> Trie k v -> Trie k v -> Trie k v
merge f (Sum p q) (Sum r s) = Sum (merge f p r) (merge f q s)
}}}
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/1999#comment:14>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs