Patrick Caldon:

make goal_expansion/3 work recursively
fixes a couple of spelling errors in the manual


git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@689 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
vsc 2002-11-18 17:17:22 +00:00
parent 735c5bed1c
commit f53fdc54cb
2 changed files with 8 additions and 2 deletions

View File

@ -8784,7 +8784,11 @@ variable. In the latter case, YAP discards previous values for the
attributes.
@item The built-in @code{get_atts/2} can be used to check the values of
an attribute associated with a variable.
<<<<<<< yap.tex
@item The unification algorithm calls the user-defined predicate
=======
@item The unification algoritm calls the user-defined predicate
>>>>>>> 1.89
@t{verify_attributes/3} before trying to bind an attributed
variable. Unification will resume after this call.
@item The user-defined predicate
@ -9034,7 +9038,7 @@ the completion of @code{verify_attribute/3}. Otherwise, there might be a
danger of recursively invoking @code{verify_attribute/3}, which might bind
@code{Var}, which is not allowed inside the scope of @code{verify_attribute/3}.
Deferring unifications into the third argument of @code{verify_attribute/3}
effectively serializes th calls to @code{verify_attribute/3}.
effectively serializes the calls to @code{verify_attribute/3}.
Assuming that the code resides in the file @file{domain.yap}, we
can use it via:

View File

@ -332,7 +332,9 @@ module(N) :-
'$expand_goal2'(G, M, GF, M) :-
'$pred_goal_expansion_on',
% make sure we do not try to expand conjs, etc...
user:goal_expansion(G,M,GF), !.
user:goal_expansion(G,M,GF0), !,
% allow recursive goal expansion
'$expand_goal2'(GF0,M,GF,M).
'$expand_goal2'(G, M, G, M).