Author: lwall
Date: 2008-11-27 08:21:32 +0100 (Thu, 27 Nov 2008)
New Revision: 24080

Modified:
   docs/Perl6/Spec/S03-operators.pod
   src/perl6/STD.pm
Log:
[STD] not() etc. is a function call
[S03] prefix:<^> no longer tries to get fancy with lists


Modified: docs/Perl6/Spec/S03-operators.pod
===================================================================
--- docs/Perl6/Spec/S03-operators.pod   2008-11-27 06:14:03 UTC (rev 24079)
+++ docs/Perl6/Spec/S03-operators.pod   2008-11-27 07:21:32 UTC (rev 24080)
@@ -12,9 +12,9 @@
 
   Maintainer: Larry Wall <[EMAIL PROTECTED]>
   Date: 8 Mar 2004
-  Last Modified: 7 Nov 2008
+  Last Modified: 26 Nov 2008
   Number: 3
-  Version: 146
+  Version: 147
 
 =head1 Overview
 
@@ -245,6 +245,14 @@
 
     a(1)
 
+In term position, any identifier followed immediately by a
+parenthesized expression is always parsed as a term representing
+a function call even if that identifier also has a prefix meaning,
+so you never have to worry about precedence in that case.  Hence:
+
+    not($x) + 1         # means (not $x) + 1
+    abs($x) + 1         # means (abs $x) + 1
+
 =item *
 
 Pair composers
@@ -2890,10 +2898,6 @@
 
     for ^4 { say $_ } # 0, 1, 2, 3
 
-If applied to a list, it generates a multidimensional set of subscripts.
-
-    for ^(3,3) { ... } # (0,0)(0,1)(0,2)(1,0)(1,1)(1,2)(2,0)(2,1)(2,2)
-
 If applied to a type name, it indicates the metaclass instance instead,
 so C<^Moose> is short for C<HOW(Moose)> or C<Moose.HOW>.  It still kinda
 means "what is this thing's domain" in an abstract sort of way.

Modified: src/perl6/STD.pm
===================================================================
--- src/perl6/STD.pm    2008-11-27 06:14:03 UTC (rev 24079)
+++ src/perl6/STD.pm    2008-11-27 07:21:32 UTC (rev 24080)
@@ -3271,7 +3271,7 @@
 token term:identifier ( --> Term )
 {
     :my $t;
-    <identifier>
+    <identifier> <?before ['.'?'(']?>
     { $t = $<identifier>.text; }
     <args( $ยข.is_type($t) )>
     {{

Reply via email to