Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Mention that "if 0 {...}" slips.
  • Loading branch information
skids committed Dec 25, 2015
1 parent 3a096df commit 47091a7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions doc/Language/control.pod
Expand Up @@ -141,8 +141,8 @@ conditionally. Do note that the condition is still always evaluated first:
The statement modifier form is probably best used sparingly.
The C<if> statement itself will either return an empty list, if it does not
run the block, or it will return the value which the block produces:
The C<if> statement itself will either L<slip|/type/Slip> us an empty list, if
it does not run the block, or it will return the value which the block produces:
my $c = 0; say (1, (if 1 { $c += 42; 2; }), 3, $c); # says "1 2 3 42"
my $d = 0; say (1, (if 0 { $d += 42; 2; }), 3, $d); # says "1 3 0"
Expand Down

0 comments on commit 47091a7

Please sign in to comment.