hegg-0.1.0.0: Fast equality saturation in Haskell
Safe HaskellSafe-Inferred
LanguageHaskell2010

Data.Equality.Graph.Classes

Description

Module for the definition of EClass.

Synopsis

Documentation

data EClass l Source #

An e-class (an equivalence class of terms) of a language l.

Intuitively, an e-graph is a set of equivalence classes (e-classes). Each e-class is a set of e-nodes representing equivalent terms from a given language, and an e-node is a function symbol paired with a list of children e-classes.

Constructors

EClass 

Fields

  • eClassId :: !ClassId

    E-class identifier

  • eClassNodes :: !(Set (ENode l))

    E-nodes in this class

  • eClassData :: Domain l

    The analysis data associated with this eclass.

  • eClassParents :: !(NodeMap l ClassId)

    E-nodes which are parents of this e-class and their corresponding e-class ids. We found a mapping from nodes to e-class ids a better representation than [(ENode l, ClassId)], and we get de-duplication built-in.

Instances

Instances details
(Show (Domain l), Show1 l) => Show (EClass l) Source # 
Instance details

Defined in Data.Equality.Graph.Classes

Methods

showsPrec :: Int -> EClass l -> ShowS #

show :: EClass l -> String #

showList :: [EClass l] -> ShowS #