blob: 0aec91a0fe867e30e2116be88698237e3bef1971 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
{-# language TypeInType, ScopedTypeVariables #-}
module Silly where
import Type.Reflection (Typeable, typeRep, TypeRep)
import Type.Reflection.Unsafe (mkTrApp)
import GHC.Exts (TYPE, RuntimeRep (..))
import Data.Kind (Type)
mkTrFun :: forall (r1 :: RuntimeRep) (r2 :: RuntimeRep)
(a :: TYPE r1) (b :: TYPE r2).
TypeRep a -> TypeRep b -> TypeRep ((a -> b) :: Type)
mkTrFun a b = typeRep `mkTrApp` a `mkTrApp` b
-- originally reported that there was no (Typeable LiftedRep) instance,
-- presumably to overeager RuntimeRep defaulting
|