ideas-1.3.1: Feedback services for intelligent tutoring systems

Maintainerbastiaan.heeren@ou.nl
Stabilityprovisional
Portabilityportable (depends on ghc)
Safe HaskellNone
LanguageHaskell98

Ideas.Common.Rewriting.Difference

Description

Compute the difference of two terms generically, taking associativity into account.

Synopsis

Documentation

difference :: IsTerm a => a -> a -> Maybe (a, a) Source

differenceEqual :: IsTerm a => (a -> a -> Bool) -> a -> a -> Maybe (a, a) Source

This function returns the difference, except that the returned terms should be logically equivalent. Nothing can signal that there is no difference, or that the terms to start with are not equivalent.

differenceWith :: View Term a -> a -> a -> Maybe (a, a) Source

differenceEqualWith :: View Term a -> (a -> a -> Bool) -> a -> a -> Maybe (a, a) Source