Re: [svn:perl6-synopsis] r8520 - doc/trunk/design/syn

2006-04-02 Thread Dr.Ruud
Larry Wall schreef:
 Ruud H.G. van Tol:
 Uri Guttman:

 When cast into an array, you can access all the positional
 arguments; Into a hash, all named arguments; Into a scalar, the
 invocant; Into code, into slurpy nameless block.
 
 The last 'into' should be 'the'.

And it has become 'its', which is clearer.


 s/Into/into/g
 
 s[ s ( .* ) g ][s:g$0]
 
 TomTiedy

Ack

-- 
Affijn, Ruud

Gewoon is een tijger.
(posted via news://nntp.perl.org)


[svn:perl6-synopsis] r8520 - doc/trunk/design/syn

2006-04-01 Thread autrijus
Author: autrijus
Date: Sat Apr  1 10:32:53 2006
New Revision: 8520

Modified:
   doc/trunk/design/syn/S02.pod

Log:
* S02: destill the compoments of an Arguments object, and
   specify the $() @() %() () casting forms for them.

Modified: doc/trunk/design/syn/S02.pod
==
--- doc/trunk/design/syn/S02.pod(original)
+++ doc/trunk/design/syn/S02.podSat Apr  1 10:32:53 2006
@@ -14,7 +14,7 @@
   Date: 10 Aug 2004
   Last Modified: 1 Apr 2006
   Number: 2
-  Version: 18
+  Version: 19
 
 This document summarizes Apocalypse 2, which covers small-scale
 lexical items and typological issues.  (These Synopses also contain
@@ -393,6 +393,17 @@
 bound to.  Some bindings are sensitive to multiple dimensions while
 others are not.
 
+You may cast CArguments to other types with a prefix sigil operator:
+
+$args = \3; # same as $args = \(3)
+$$args; # same as $args as Scalar or Scalar($args)
+@$args; # same as '$args as Array  or Array($args)
+%$args; # same as '$args as Hash   or Hash($args)
+$args; # same as '$args as Code   or Hash($args)
+
+Casted as an array, you can access to all positionals.  Casted as a hash, all
+nameds.  As a scalar, the invocant.  As a code, the slurpy nameless block.
+
 =item *
 
 A signature object (CSignature) may be created with coloned parens:
@@ -430,7 +441,7 @@
 foo:(Int,Num)
 
 It still just returns a function reference.  A call may also be partially
-applied by using a tuple literal as a postfix operator:
+applied by using an argument list literal as a postfix operator:
 
 foo\(1,2,3,:miceblind)
 


RE: [svn:perl6-synopsis] r8520 - doc/trunk/design/syn

2006-04-01 Thread Joe Gottman


 -Original Message-
 +You may cast CArguments to other types with a prefix sigil operator:
 +
 +$args = \3; # same as $args = \(3)
 +$$args; # same as $args as Scalar or Scalar($args)
 +@$args; # same as '$args as Array  or Array($args)
 +%$args; # same as '$args as Hash   or Hash($args)
 +$args; # same as '$args as Code   or Hash($args)


Shouldn't this last one be
  +$args; # same as '$args as Code   or Code($args)

Joe Gottman
 



Re: [svn:perl6-synopsis] r8520 - doc/trunk/design/syn

2006-04-01 Thread Uri Guttman
 a == autrijus  [EMAIL PROTECTED] writes:

  a +You may cast CArguments to other types with a prefix sigil operator:
  a +
  a +$args = \3; # same as $args = \(3)
  a +$$args; # same as $args as Scalar or Scalar($args)
  a +@$args; # same as '$args as Array  or Array($args)
  a +%$args; # same as '$args as Hash   or Hash($args)
  a +$args; # same as '$args as Code   or Hash($args)
  a +

  a +Casted as an array, you can access to all positionals.  Casted as
  a +a hash, all nameds.  As a scalar, the invocant.  As a code, the
  a +slurpy nameless block.

s/casted/cast/g

and i would word those as 'cast into an array'. here is my rewrite:

When cast into an array, you can access all the positional
arguments; Into a hash, all named arguments; Into a scalar, the
invocant; Into code, into slurpy nameless block.

uri

-- 
Uri Guttman  --  [EMAIL PROTECTED]   http://www.stemsystems.com
--Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
Search or Offer Perl Jobs    http://jobs.perl.org


Re: [svn:perl6-synopsis] r8520 - doc/trunk/design/syn

2006-04-01 Thread Ruud H.G. van Tol
Uri Guttman wrote:

   When cast into an array, you can access all the positional
   arguments; Into a hash, all named arguments; Into a scalar, the
   invocant; Into code, into slurpy nameless block.

The last 'into' should be 'the'.

s/Into/into/g

-- 
Affijn, Ruud




Re: [svn:perl6-synopsis] r8520 - doc/trunk/design/syn

2006-04-01 Thread Larry Wall
On Sun, Apr 02, 2006 at 02:15:46AM +0200, Ruud H.G. van Tol wrote:
: Uri Guttman wrote:
: 
:  When cast into an array, you can access all the positional
:  arguments; Into a hash, all named arguments; Into a scalar, the
:  invocant; Into code, into slurpy nameless block.
: 
: The last 'into' should be 'the'.
: 
: s/Into/into/g

s[ s ( .* ) g ][s:g$0]

TomTiedy