Module Language.Curry.CheckDetUsage

Author
Michael Hanus
Version
February 2023

Deterministic operations are marked by wrapping the result type of top-level operations with the type synonym Prelude.DET. This module defines the operation checkDetUse which detects unintended uses of this type synonym.

See program DetOpts.curry in the package directory examples for some examples.

Exported Functions:

Exported Functions


containsDetOperations :: CurryProg -> Bool  Deterministic 

Does a Curr program contains operations with DET annotations? Since DET is a type synonym which will be removed by the front end, the AbstractCurry program must be an untyped AbstractCurry program.


checkDetUse :: CurryProg -> [((String, String), String)]  Deterministic 

Returns messages about unintended uses of type synonym DET in a Curry program. Since DET is a type synonym which will be removed by the front end, the AbstractCurry program must be an untyped AbstractCurry program.