Author: lwall
Date: 2009-07-29 19:59:03 +0200 (Wed, 29 Jul 2009)
New Revision: 27801

Modified:
   docs/Perl6/Spec/S06-routines.pod
Log:
[S06] only add @_ and %_ to default sig if actually used in body


Modified: docs/Perl6/Spec/S06-routines.pod
===================================================================
--- docs/Perl6/Spec/S06-routines.pod    2009-07-29 17:57:30 UTC (rev 27800)
+++ docs/Perl6/Spec/S06-routines.pod    2009-07-29 17:59:03 UTC (rev 27801)
@@ -15,8 +15,8 @@
 
     Created: 21 Mar 2003
 
-    Last Modified: 26 Jun 2009
-    Version: 110
+    Last Modified: 29 Jul 2009
+    Version: 111
 
 
 This document summarizes Apocalypse 6, which covers subroutines and the
@@ -125,10 +125,15 @@
 
     sub foo {...}
 
-This is equivalent to
+This is equivalent to one of:
 
+    sub foo () {...}
+    sub foo (*...@_) {...}
+    sub foo (*%_) {...}
     sub foo (*...@_, *%_) {...}
 
+depending on whether either or both of those variables are used in the body of 
the routine.
+
 Positional arguments implicitly come in via the C<@_> array, but
 unlike in PerlĀ 5 they are C<readonly> aliases to actual arguments:
 

Reply via email to