![]() |
YAP 7.1.0
|
Support for co-routining
class attr_unify_hook/2 |
attr_unify_hook(+ AttValue,+ VarValue)
Hook that must be defined in the module an attributed variable refers to Is is called after the attributed variable has been unified with a non-var term, possibly another attributed variable AttValue is the attribute that was associated to the variable in this module and VarValue is the new value of the variable Normally this predicate fails to veto binding the variable to VarValue, forcing backtracking to undo the binding If VarValue is another attributed variable the hook often combines the two attribute and associates the combined attribute with VarValue using put_attr/3
class freeze/2 |
freeze(? X,: G)
Delay execution of goal G until the variable X is bound
class dif/2 |
dif( X, Y)
Succeed if the two arguments do not unify A call to dif/2 will suspend if unification may still succeed or fail, and will fail if they always unify
class when/2 |
when(+ C,: G)
Delay execution of goal G until the conditions C are satisfied The conditions are of the following form:
Note that when/2 will fail if the conditions fail
class frozen/2 |
frozen( X, G)
Unify G with a conjunction of goals suspended on variable X, or true
if no goal has suspended
Definition at line 1 of file corout.yap.