blob: cb05bf2c23010e2d5b65013a3a8bc8feadce93a1 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
|
{-# LANGUAGE RoleAnnotations #-}
-- Also see Note [Order of Coercible Instances]
module T9117 where
import Data.Coerce
newtype Phant a = MkPhant Char
type role Phant representational
ex1 :: Phant Bool
ex1 = coerce (MkPhant 'x' :: Phant Int)
|