Skip to content

Commit 7d40c87

Browse files
committed
Changes anchors and reflows
1 parent ec83ae2 commit 7d40c87

File tree

1 file changed

+18
-13
lines changed

1 file changed

+18
-13
lines changed

doc/Language/operators.pod6

Lines changed: 18 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2019,25 +2019,30 @@ my %loser = points => 20, misses => 10;
20192019
20202020
=head1 Conditional operator precedence
20212021
2022+
X<|operator,ternary>
2023+
X<|operator,conditional>.
20222024
=head2 infix C<?? !!>
20232025
2024-
Also called X<ternary operator|operator,ternary> or X<conditional operator|operator,conditional>.
2025-
2026-
C<$condition ?? $true !! $false> evaluates C<$condition> and returns the expression right behind ??, in this case C<$true> if it is C<True>, otherwise evaluates and returns the expression behind !!, C<$false> in this case.
2026+
Also called I<ternary> or I<conditional> operator. C<$condition ?? $true !!
2027+
$false> evaluates C<$condition> and returns the expression right behind ??,
2028+
in this case C<$true> if it is C<True>, otherwise evaluates and returns
2029+
the expression behind !!, C<$false> in this case.
20272030
2031+
X<|operator,flipflop>
20282032
=head2 infix C«ff»
20292033
20302034
sub infix:<ff>(Mu $a, Mu $b)
20312035
2032-
Also called the X<flipflop operator|ff>.
2036+
Also called the I<flipflop operator>.
20332037
2034-
Compares both arguments to C<$_> (that is, C<$_ ~~ $a> and C<$_ ~~
2035-
$b>). Evaluates to C<False> until the left-hand smartmatch is C<True>, at which
2036-
point it evaluates to C<True> until the right-hand smartmatch is C<True>.
2038+
Compares both arguments to C<$_> (that is, C<$_ ~~ $a> and C<$_ ~~ $b>).
2039+
Evaluates to C<False> until the left-hand smartmatch is C<True>, at
2040+
which point it evaluates to C<True> until the right-hand smartmatch is
2041+
C<True>.
20372042
2038-
In effect, the left-hand argument is the "start" condition and the right-hand
2039-
is the "stop" condition. This construct is typically used to pick up only a
2040-
certain section of lines. For example:
2043+
In effect, the left-hand argument is the "start" condition and the
2044+
right-hand is the "stop" condition. This construct is typically used to
2045+
pick up only a certain section of lines. For example:
20412046
20422047
=begin code :allow<B V>
20432048
my $excerpt = q:to/END/;
@@ -2058,9 +2063,9 @@ my @codelines = gather for $excerpt.lines {
20582063
say @codelines.join("\n");
20592064
=end code
20602065
2061-
After matching the start condition, the operator will then match the same C<$_>
2062-
to the stop condition and act accordingly if successful. In this example, only
2063-
the first element is printed:
2066+
After matching the start condition, the operator will then match the
2067+
same C<$_> to the stop condition and act accordingly if successful. In
2068+
this example, only the first element is printed:
20642069
20652070
for <AB C D B E F> {
20662071
say $_ if /A/ ff /B/; # OUTPUT: «AB␤»

0 commit comments

Comments
 (0)