unification-fd-0.10.0.1: Simple generic unification algorithms.

CopyrightCopyright (c) 2007--2015 wren gayle romano
LicenseBSD
Maintainerwren@community.haskell.org
Stabilityhighly experimental
Portabilitysemi-portable (Rank2Types, MPTCs,...)
Safe HaskellNone
LanguageHaskell98

Control.Unification.Ranked.STVar

Description

A ranked variant of Control.Unification.STVar.

Synopsis

Documentation

data STRVar s t Source

A ranked unification variable implemented by STRefs. In addition to the STRef for the term itself, we also track the variable's ID (to support visited-sets) and rank (to support weighted path compression).

Instances

data STRBinding s a Source

A monad for handling STRVar bindings.

runSTRBinding :: (forall s. STRBinding s a) -> a Source

Run the ST ranked binding monad. N.B., because STRVar are rank-2 quantified, this guarantees that the return value has no such references. However, in order to remove the references from terms, you'll need to explicitly apply the bindings.