diff options
Diffstat (limited to 'testsuite/tests/gadt/T3651.hs')
-rw-r--r-- | testsuite/tests/gadt/T3651.hs | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/testsuite/tests/gadt/T3651.hs b/testsuite/tests/gadt/T3651.hs new file mode 100644 index 0000000000..9f671905c8 --- /dev/null +++ b/testsuite/tests/gadt/T3651.hs @@ -0,0 +1,17 @@ +{-# LANGUAGE GADTs #-} +{-# LANGUAGE TypeFamilies #-} + +module T3651 where + +data Z a where + U :: Z () + B :: Z Bool + +unsafe1 :: Z a -> Z a -> a +unsafe1 B U = () + +unsafe2 :: a ~ b => Z b -> Z a -> a +unsafe2 B U = () + +unsafe3 :: a ~ b => Z a -> Z b -> a +unsafe3 B U = True |