1
Fork 0
solar-conflux/purescript/free/src/Exists.purs

15 lines
348 B
Plaintext
Raw Normal View History

2023-10-29 02:17:37 +02:00
module Existsential where
import Prelude
import Unsafe.Coerce (unsafeCoerce)
foreign import data Test :: forall k. (k -> Type) -> Type
foreign import data Exists :: forall a b. (a -> b) -> b
mkExists :: forall f a. f a -> Exists f
mkExists = unsafeCoerce
runExists :: forall f r. (forall a. f a -> r) -> Exists f -> r
runExists = unsafeCoerce