Skip to content

Commit b767e4d

Browse files
committed
xor is not a standard operator
1 parent 036c59e commit b767e4d

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

src/lib/ops_and_meta_predicates.pl

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
:- op(200, xfy, ^).
2727
:- op(500, yfx, /\).
2828
:- op(500, yfx, \/).
29-
:- op(500, yfx, xor).
3029
:- op(400, yfx, div).
3130
:- op(400, yfx, //).
3231
:- op(400, yfx, rdiv).

src/tests/arithmetic.pl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -258,14 +258,14 @@
258258
Or2 is Y \/ X,
259259
Or == OrExpected,
260260
Or == Or2,
261-
Xor is X xor Y,
262-
Xor2 is Y xor X,
261+
Xor is xor(X, Y),
262+
Xor2 is xor(Y, X),
263263
Xor == XorExpected,
264264
Xor2 == Xor,
265265

266266
call(is, And3, X /\ Y),
267267
call(is, Or3, X \/ Y),
268-
call(is, Xor3, X xor Y),
268+
call(is, Xor3, xor(X, Y)),
269269
And3 == And,
270270
Or3 == Or,
271271
Xor3 == Xor.
@@ -613,7 +613,7 @@
613613
]), arithmetic_tests:test_and_or_xor(X, Y, AndExpected, OrExpected, XorExpected)),
614614
\+ catch(_ is 1 /\ 2.0, _, false),
615615
\+ catch(_ is 1 \/ 2.0, _, false),
616-
\+ catch(_ is 1 xor 2.0, _, false)
616+
\+ catch(_ is xor(1, 2.0), _, false)
617617
)).
618618

619619
test("mod_rem", (

0 commit comments

Comments
 (0)