Skip to content

Commit

Permalink
fix pod error
Browse files Browse the repository at this point in the history
  • Loading branch information
coke committed Jun 4, 2018
1 parent 4234cc2 commit 779310a
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions doc/Language/functions.pod6
Expand Up @@ -1034,6 +1034,7 @@ sub are-equal (Int $x, Int $y --> Bool(Int) ) { $x - $y };
for (2,4) X (1,2) -> ($a,$b) {
say "Are $a and $b equal? ", are-equal($a, $b);
} # OUTPUT: «Are 2 and 1 equal? True␤Are 2 and 2 equal? False␤Are 4 and 1 equal? True␤Are 4 and 2 equal? True␤»
=end code
In this case, we are coercing an C<Int> to a C<Bool>, which is then printed (put
into a string context) in the C<for> loop that calls the function.
Expand Down

0 comments on commit 779310a

Please sign in to comment.