Module FlatCurry.Transform.ExecND

Author
Michael Hanus, Steven Libby
Version
August 2025

Implementation of transforming FlatCurry expressions by applying non-deterministically defined expressions transformations as long as possible with a chaotic (non-deterministic) strategy.

Exported Functions:

Exported Functions


transformExprND :: (() -> (Int, [Int]) -> Expr -> (Expr, String, Int)) -> Int -> Expr -> Expr  Deterministic 

Simplifies a FlatCurry expression according to some expression transformation. Since the expression transformation can be non-deterministically defined, we pass it as a function which is similarly to passing it via run-time choice. The second argument is the maximum number of transformation steps to be applied. If the number is -1, then keep going until no transformation can be applied.

To apply transformation steps, a subexpression is non-deterministically selected.

Further infos:
  • might behave indeterministically