Skip to content

Commit

Permalink
Expand documentation of loose xor
Browse files Browse the repository at this point in the history
Add links in loose or / xor to strict sections
Summarize chaining behavior
  • Loading branch information
dmaestro committed Aug 22, 2017
1 parent aeddc02 commit 3186181
Showing 1 changed file with 12 additions and 5 deletions.
17 changes: 12 additions & 5 deletions doc/Language/operators.pod6
Expand Up @@ -2264,7 +2264,7 @@ behaviour:
=head2 infix C«or»
Same as C<infix ||>, except with looser precedence.
Same as L<infix C<||>|#infix || >, except with looser precedence.
Returns the first argument that evaluates to C<True> in boolean context,
or otherwise the last argument, it short-circuits. Please note that C<or> is easy
Expand Down Expand Up @@ -2303,10 +2303,17 @@ while a L<Failure> never is:
=head2 infix C«xor»
Returns the argument that evaluates to C<True> in boolean context, if and
only if the other argument evaluates to C<False> in boolean context. If
both arguments evaluate to C<True>, returns the last argument. If both
arguments evalute to C<False>, returns a false value.
Same as L<infix C<^^>|#infix ^^>, except with looser precedence.
Returns the operand that evaluates to C<True> in boolean context, if and
only if the other operand evaluates to C<False> in boolean context. If
both operands evaluate to C<False>, returns the last argument. If both
operands evalute to C<True>, returns C<Nil>.
When chaining, returns the operand that evaluates to C<True>, if and
only if there is one such operand. If more than one operand is true,
it short-cicuits after evaluating the second and returns C<Nil>. If all
operands are false, returns the last one.
=head1 Sequencer Precedence
Expand Down

0 comments on commit 3186181

Please sign in to comment.