imagine you have the equivalent definition married_to(X,Y):- true, !, married(X,Y) ; married(Y,X).
. If true
were to fail, then we'd jump to the alternative, but since it's not going to, we're firmly on the consequent branch (of the disjunction).
IOW your code is
married_to(X,Y):- ( !, married(X,Y) ) ; ( married(Y,X) ).
and not
married_to(X,Y):- !, ( married(X,Y) ; married(Y,X) ).
It is actually equivalent to
married_to(X,Y):- !, married(X,Y).
married_to(X,Y):- married(Y,X).
Perhaps with this it is easier to get a "feeling" for what is going on here. Obviously, the second clause of the predicate is cut off. :) We're committed to the first clause, the second doesn't get a chance to work at all.