freec-unit-tests

Safe HaskellNone
LanguageHaskell2010

FreeC.IR.UnificationTests

Description

This module contains tests for FreeC.IR.Unification.

Synopsis

Documentation

testUnification :: Spec Source #

Test group for unify tests.

shouldUnifyTo :: (Type, Type) -> Type -> Converter Expectation Source #

Unifies the given type expressions and sets the expectation that the both are equal after applying the computed unificator.

shouldUnifyTo' :: (Type, Type) -> (Type, Type) -> Converter Expectation Source #

Like shouldUnifyTo' but there are two different expected outputs.

There can be different outputs for the two type expressions if they contain type synonyms.

shouldFailUnification :: Type -> Type -> Converter Expectation Source #

Unifies the given type expressions and sets the expectation that the unification fails.

shouldFailOccursCheck :: Type -> Type -> Converter Expectation Source #

Unifies the given type expressions and sets the expectation that the occurs check fails.