Shouldn’t two structurally different Prolog terms give a different output?
Was trying this example with SWI-Prolog 8.3.26:
?- op(400,xfy,***).
true.
?- X=(a***b)*c, Y=a***(b*c).
X = a***b*c,
Y = a***b*c.
?- X=(a***b)*c, Y=a***(b*c), X=Y.
false.
GNU Prolog 1.4.5 on the other hand gives me, thanks to its
context == INSIDE_LEFT_ASSOC_OP
logic in its Show_Term:
?- X=(a***b)*c, Y=a***(b*c).
X = (a***b)*c
Y = a***b*c
Edit 17.07.2021:
There is a similar problem for the prefix fy yfx combo:
?- op(400,fy,***).
true.
?- X = (***b)*c, Y= ***(b*c).
X = ***b*c,
Y = ***b*c.