FAQ
Author: pmichaud
Date: 2009-07-28 21:45:55 +0200 (Tue, 28 Jul 2009)
New Revision: 27784

Modified:
docs/Perl6/Spec/S04-control.pod
Log:
Fix incorrect specification of implicit $_ in blocks.


Modified: docs/Perl6/Spec/S04-control.pod
===================================================================
--- docs/Perl6/Spec/S04-control.pod 2009-07-28 19:37:57 UTC (rev 27783)
+++ docs/Perl6/Spec/S04-control.pod 2009-07-28 19:45:55 UTC (rev 27784)
@@ -44,7 +44,7 @@
(either explicitly or implicitly) is treated as though C<$_> were a
formal parameter:

- $func = { .print if $_ }; # Same as: $func = -> $_ { .print if $_ };
+ $func = { .print if $_ }; # Same as: $func = <-> $_ { .print if $_ };
$func("printme");

In any case, all formal parameters are the equivalent of C<my> variables

Search Discussions

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupperl6-language @
categoriesperl
postedJul 28, '09 at 7:46p
activeJul 28, '09 at 7:46p
posts1
users1
websiteperl6.org

1 user in discussion

Pugs-commits: 1 post

People

Translate

site design / logo © 2021 Grokbase