BiGUL-1.0.1: The Bidirectional Generic Update Language

Safe HaskellNone
LanguageHaskell2010

Generics.BiGUL.Error

Description

Datatypes for error traces, produced by the standard interpreters in Generics.BiGUL.Interpreter.

Synopsis

Documentation

data BiGULTrace Source #

Execution traces, which log the operations executed, intermediate sources and views, and reasons of eventual failure.

Constructors

BTSuccess

Execution successfully produces a result.

BTError BiGULError

Execution fails to produce a result.

(Show s, Show v) => BTNextSV String s v BiGULTrace

An intermediate step with the current source and view.

Show s => BTNextS String s BiGULTrace

An intermediate step with the current source.

BTBranch Int BiGULTrace

Inside a branch. Notes that branch numbering starts from 0.

BTBranches [BiGULTrace]

All branches fail.

data BiGULError Source #

Datatype of atomic errors.

Constructors

BEFail String

Fail is executed.

BESkipMismatch

When executing Skip f on a source s, the view is not f s.

BESourcePatternMismatch PatError

The source does not match with a pattern.

BEViewPatternMismatch PatError

The view does not match with a pattern.

BEInvRearrFailed PatError

The inverse rearrangement fails.

BEViewRecoveringFailed PatError

The view cannot be reconstructed.

BEDependencyMismatch

When executing Dep f _ on a view pair (v, v'), the second component v' is not f v.

BECaseExhausted

No branch in a Case statement is applicable.

BEAdaptiveBranchRevisited

After adaptation, execution still goes into an adaptative branch.

BEPreviousBranchMatched

After execution of a branch, the computed source and view satisfy the main condition of a previous branch.

BEExitConditionFailed

After execution of a branch, the updated source fails to satisfy the exit condition.

BEPostVerificationFailed

After execution of a branch, the computed source and view do not satisfy the main condition.

BEBranchUnmatched

The main condition is not satisfied by the source and view (and hence the branch is not chosen).

BEAdaptiveBranchMatched

The branch is adaptive and hence ignored.

data PatError Source #

Pattern matching errors, which also explain where the matching fails.

Constructors

PEConstantMismatch

A constant pattern/expression is matched with a different value.

PELeftMismatch

A Left pattern/expression is matched with a Right value.

PERightMismatch

A Right pattern/expression is matched with a Left value.

PEIncompatibleUpdates

Occurrences of the same variable in an expression are matched with different values.

PEMultipleUpdates

A variable that should appear at most once in an expression is however used multiple times.

PEValueUnrecoverable

A variable that should appear at least once in an expression is however absent.

PEProdL PatError

The error is on the left of a product pattern/expression.

PEProdR PatError

The error is on the right of a product pattern/expression.

PELeft PatError

The error is inside a Left pattern/expression.

PERight PatError

The error is inside a Right pattern/expression.

PEIn PatError

The error is inside a constructor pattern/expression.