Embrace -XTypeInType, add -XStarIsType
[ghc.git] / testsuite / tests / dependent / should_compile / T12176.hs
1 {-# LANGUAGE RankNTypes, DataKinds, PolyKinds, GADTs, TypeFamilies #-}
2
3 module T12176 where
4
5 import Data.Kind
6
7 data Proxy :: forall k. k -> Type where
8 MkProxy :: forall k (a :: k). Proxy a
9
10 data X where
11 MkX :: forall (k :: Type) (a :: k). Proxy a -> X
12
13 type Expr = (MkX :: forall (a :: Bool). Proxy a -> X)
14
15 type family Foo (x :: forall (a :: k). Proxy a -> X) where
16 Foo (MkX :: forall (a :: k). Proxy a -> X) = (MkProxy :: Proxy k)
17
18 type Bug = Foo Expr -- this failed with #12176