term-rewriting-0.3.0.1: Term Rewriting Library

Safe HaskellSafe
LanguageHaskell98

Data.Rewriting.Rule.Type

Synopsis

Documentation

data Term f v Source #

Constructors

Var v

Variable

Fun f [Term f v]

Function application

Instances
(Eq v, Eq f) => Eq (Term f v) Source # 
Instance details

Defined in Data.Rewriting.Term.Type

Methods

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

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

(Ord v, Ord f) => Ord (Term f v) Source # 
Instance details

Defined in Data.Rewriting.Term.Type

Methods

compare :: Term f v -> Term f v -> Ordering #

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

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

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

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

max :: Term f v -> Term f v -> Term f v #

min :: Term f v -> Term f v -> Term f v #

(Show v, Show f) => Show (Term f v) Source # 
Instance details

Defined in Data.Rewriting.Term.Type

Methods

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

show :: Term f v -> String #

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

(Pretty f, Pretty v) => Pretty (Term f v) # 
Instance details

Defined in Data.Rewriting.Term.Pretty

Methods

pretty :: Term f v -> Doc #

prettyList :: [Term f v] -> Doc #

data Rule f v Source #

Rewrite rule with left-hand side and right-hand side.

Constructors

Rule 

Fields

Instances
(Eq v, Eq f) => Eq (Rule f v) Source # 
Instance details

Defined in Data.Rewriting.Rule.Type

Methods

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

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

(Ord v, Ord f) => Ord (Rule f v) Source # 
Instance details

Defined in Data.Rewriting.Rule.Type

Methods

compare :: Rule f v -> Rule f v -> Ordering #

(<) :: Rule f v -> Rule f v -> Bool #

(<=) :: Rule f v -> Rule f v -> Bool #

(>) :: Rule f v -> Rule f v -> Bool #

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

max :: Rule f v -> Rule f v -> Rule f v #

min :: Rule f v -> Rule f v -> Rule f v #

(Show v, Show f) => Show (Rule f v) Source # 
Instance details

Defined in Data.Rewriting.Rule.Type

Methods

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

show :: Rule f v -> String #

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

(Pretty f, Pretty v) => Pretty (Rule f v) # 
Instance details

Defined in Data.Rewriting.Rule.Pretty

Methods

pretty :: Rule f v -> Doc #

prettyList :: [Rule f v] -> Doc #

map :: (f -> f') -> (v -> v') -> Rule f v -> Rule f' v' Source #

mapSides :: (Term f v -> Term f' v') -> Rule f v -> Rule f' v' Source #