blob: 4caf1c26329368792c0c9cb3ef06b22d79f0bb44 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
|
{-# LANGUAGE RoleAnnotations, RankNTypes, ScopedTypeVariables #-}
import GHC.Prim (coerce, Coercible)
newtype List a = List [a]
data T f = T (f Int)
newtype NT1 a = NT1 (a -> Int)
newtype NT2 a = NT2 (a -> Int)
foo :: T NT1 -> T NT2
foo = coerce
main = return ()
|