Next: , Previous: , Up: amb api   [Index]


1.4.1.4 Utility functions and syntaxes

The following bindings are exported by the library (vicare language-extensions amb).

Syntax: amb-assert ?expr

Evaluate ?expr and if the result is true return it; if the result is false reject the latest amb choice.

(amb-assert ?expr) → (or ?expr (amb))
Parameter: amb-backtrack-log

Hold a thunk to be called every time amb, or any of its derivatives, backtracks to reject a previous choice. It is initialised to void.