Yes it is. Because it's awkward to write:
in reply to Anyone use "xor" in conditionals?
specially when either condition is either expensive,
or has side-effects.
if ((COND1 || COND2) && !(COND1 && COND2))
A while ago, I was writing a small script that recursively
compared directories (and no, plain diff didn't do, although
the script called diff repeatedly). Since I was interested
in the similarities instead of the differences, at one moment
next if -d $dir1 xor -d $dir2
If either of the arguments wasn't a directory, but the
other was, they couldn't match. But if both were, or both
weren't, furthermore analysis was necessary.
And yes, I know, xor can be written using other
primitives as well. But that's not an argument, unless you
also think 'for', 'while' and other looping constructs
are redundant, because we have 'goto'.