unison-core1-0.0.0
Safe HaskellSafe-Inferred
LanguageHaskell2010

Unison.ABT.Normalized

Documentation

data ABT f v Source #

Constructors

Abs v (Term f v) 
Tm (f v (Term f v)) 

Instances

Instances details
(forall a b. (Show a, Show b) => Show (f a b), Show v) => Show (ABT f v) Source # 
Instance details

Defined in Unison.ABT.Normalized

Methods

showsPrec :: Int -> ABT f v -> ShowS #

show :: ABT f v -> String #

showList :: [ABT f v] -> ShowS #

(forall a b. (Eq a, Eq b) => Eq (f a b), Bifunctor f, Bifoldable f, Var v) => Eq (ABT f v) Source # 
Instance details

Defined in Unison.ABT.Normalized

Methods

(==) :: ABT f v -> ABT f v -> Bool #

(/=) :: ABT f v -> ABT f v -> Bool #

data Term f v Source #

Constructors

Term 

Fields

Bundled Patterns

pattern TAbs :: Var v => v -> Term f v -> Term f v 
pattern TTm :: (Var v, Bifoldable f) => f v (Term f v) -> Term f v 
pattern TAbss :: Var v => [v] -> Term f v -> Term f v 

Instances

Instances details
(forall a b. (Show a, Show b) => Show (f a b), Show v) => Show (Term f v) Source # 
Instance details

Defined in Unison.ABT.Normalized

Methods

showsPrec :: Int -> Term f v -> ShowS #

show :: Term f v -> String #

showList :: [Term f v] -> ShowS #

(forall a b. (Eq a, Eq b) => Eq (f a b), Bifunctor f, Bifoldable f, Var v) => Eq (Term f v) Source # 
Instance details

Defined in Unison.ABT.Normalized

Methods

(==) :: Term f v -> Term f v -> Bool #

(/=) :: Term f v -> Term f v -> Bool #

class (Bifoldable f, Bifunctor f) => Align f where Source #

Methods

align :: Applicative g => (vl -> vr -> g vs) -> (el -> er -> g es) -> f vl el -> f vr er -> Maybe (g (f vs es)) Source #

alpha :: Align f => Var v => Map v v -> Term f v -> Term f v -> Either (Term f v, Term f v) () Source #

renames :: (Var v, Ord v, Bifunctor f, Bifoldable f) => Map v Int -> Map v v -> Term f v -> Term f v Source #

rename :: (Var v, Ord v, Bifunctor f, Bifoldable f) => v -> v -> Term f v -> Term f v Source #

transform :: (Var v, Bifunctor g, Bifoldable f, Bifoldable g) => (forall a b. f a b -> g a b) -> Term f v -> Term g v Source #