blob: 77c68ee92eb63adbf7ea9895c4cbc4a42f2c7ac4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
|
{-# LANGUAGE RankNTypes, GADTs, KindSignatures #-}
module T14320
where
import Data.Kind (Type)
data Exp :: Type where
Lit :: (Int -> Exp)
newtype TypedExp :: Type -> Type where
TEGood :: forall a . (Exp -> (TypedExp a))
-- The only difference here is that the type is wrapped in parentheses,
-- but GHC 8.0.1 rejects this program
--
newtype TypedExpToo :: Type -> Type where
TEBad :: (forall a . (Exp -> (TypedExpToo a)))
|