FIXED: meta_predicate/1 declaration of (',')/3 and (;)/3.

This commit is contained in:
Markus Triska
2021-11-20 22:43:07 +01:00
parent e05dd5ebb5
commit 6610ba67c4

View File

@@ -4,7 +4,7 @@
:- use_module(library(dif)). :- use_module(library(dif)).
:- meta_predicate if_(1, 0, 0). :- meta_predicate(if_(1, 0, 0)).
if_(If_1, Then_0, Else_0) :- if_(If_1, Then_0, Else_0) :-
call(If_1, T), call(If_1, T),
@@ -50,12 +50,12 @@ i_tpartition([X|Xs], P_2, Ts0, Fs0) :-
, ( Fs0 = [X|Fs], Ts0 = Ts ) ), , ( Fs0 = [X|Fs], Ts0 = Ts ) ),
i_tpartition(Xs, P_2, Ts, Fs). i_tpartition(Xs, P_2, Ts, Fs).
:- meta_predicate ','(0, 0, ?). :- meta_predicate(','(1, 1, ?)).
','(A_1, B_1, T) :- ','(A_1, B_1, T) :-
if_(A_1, call(B_1, T), T = false). if_(A_1, call(B_1, T), T = false).
:- meta_predicate ';'(0, 0, ?). :- meta_predicate(';'(1, 1, ?)).
';'(A_1, B_1, T) :- ';'(A_1, B_1, T) :-
if_(A_1, T = true, call(B_1, T)). if_(A_1, T = true, call(B_1, T)).