summaryrefslogtreecommitdiff
path: root/testsuite/tests/indexed-types/should_fail/T12522a.hs
blob: eb855f41713d02c044c6a381426fcd2796b7699c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE KindSignatures #-}
{-# LANGUAGE TypeFamilyDependencies #-}
{-# LANGUAGE TypeOperators #-}

module T12522a where

newtype I a = I a

type family Curry (as :: [*]) b = f | f -> as b where
    Curry '[] b = I b
    Curry (a:as) b = a -> Curry as b

data Uncurried (as :: [*]) b

def :: Curry as b -> Uncurried as b
def = undefined

-- test :: Uncurried [Int, String] String
test = def $ \n s -> I $ show n ++ s