{-# OPTIONS_HADDOCK show-extensions #-}
{-# LANGUAGE DeriveGeneric #-}
module Unbound.Generics.LocallyNameless.Unsafe
(
unsafeUnbind
) where
import Unbound.Generics.LocallyNameless.Alpha
import Unbound.Generics.LocallyNameless.Bind
unsafeUnbind :: (Alpha p, Alpha t) => Bind p t -> (p, t)
unsafeUnbind :: forall p t. (Alpha p, Alpha t) => Bind p t -> (p, t)
unsafeUnbind (B p
p t
t) = (p
p, AlphaCtx -> NthPatFind -> t -> t
forall a. Alpha a => AlphaCtx -> NthPatFind -> a -> a
open AlphaCtx
initialCtx (p -> NthPatFind
forall a. Alpha a => a -> NthPatFind
nthPatFind p
p) t
t)