summaryrefslogtreecommitdiff
path: root/testsuite/tests/indexed-types/should_compile/GADT6.hs
blob: 0e976b441e0e6901effa823ba0e23134de424c0b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
{-# LANGUAGE TypeFamilies, GADTs #-}

module GADT6 where

data Pair p  where
  Pair :: p~(a,b) => a -> b -> Pair p
  -- this works:
  -- Pair :: a -> b -> Pair (a,b)

foo :: Pair ((), ()) -> a
foo (Pair () ()) = undefined