SWI-portability changes
git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@2088 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
18
pl/utils.yap
18
pl/utils.yap
@@ -17,13 +17,17 @@
|
||||
|
||||
once(G) :- '$execute'(G), !.
|
||||
|
||||
if(X,Y,_Z) :-
|
||||
CP is '$last_choice_pt',
|
||||
'$execute'(X),
|
||||
'$clean_ifcp'(CP),
|
||||
'$execute'(Y).
|
||||
if(_X,_Y,Z) :-
|
||||
'$execute'(Z).
|
||||
if(X,Y,Z) :-
|
||||
yap_hacks:env_choice_point(CP0),
|
||||
(
|
||||
CP is '$last_choice_pt',
|
||||
'$call'(X,CP,if(X,Y,Z),M),
|
||||
'$execute'(X),
|
||||
'$clean_ifcp'(CP),
|
||||
'$call'(Y,CP,if(X,Y,Z),M)
|
||||
;
|
||||
'$call'(Z,CP,if(X,Y,Z),M)
|
||||
).
|
||||
|
||||
call(X,A) :- '$execute'(X,A).
|
||||
|
||||
|
||||
Reference in New Issue
Block a user