blob: 5a74776c27a9db3fbd416167c67ef38c6569c8a9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
{-# LANGUAGE TypeFamilies #-}
module Simple12 where
type family F a
same :: a -> a -> a
same = undefined
mkf :: a -> F a
mkf p = undefined
-- works with either of these signatures
-- foo :: a ~ F a => a -> a
-- foo :: a ~ F a => a -> F a
foo p = same p (mkf p)
|