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

2007-01-31 Thread TSa
HaloO, Larry Wall wrote: ...I think that should work. The *-1 value just means one before Whatever, and the dwim is, as you say, lazy. Or perhaps this generalizes to an odd form of currying: replicate := * xx 42; Ohh, let me get that in my own words: the rhs replicates a Whatever into

Re: Whatever arithmetic

2007-01-31 Thread TSa
HaloO I wrote: my @a = 0,1,2,3,4,5,6,7,8,9; my $i = 5..*; say @a[$i]; # prints 5 6 7 8 9 And how about my $i = 5..*-1; say @a[$i]; # prints 5 6 7 8? The rational would be that the -1 goes into the range Whatever value, that is when it comes to expanding it inside the array

Re: Enhancing array indices

2007-01-31 Thread TSa
HaloO Larry Wall wrote: But maybe you meant @x[*+2 .. *-1]? And @x[*] would be @x[*+0..^*-0] written out that way. How far can we drive the dwimmy use of the three values that determine array access, i.e first and last index and length. E.g. would @x[*+0..*/2] roughly slice to the

Re: Enhancing array indices

2007-01-31 Thread TSa
HaloO, I wrote: E.g. would @x[*+0..*/2] roughly slice to the middle of the array? Hmm, this might not work. It should be @x[*+0..*-1-*/2] on the footing that the last * is dwiming the length. This implies that dispatches to infix:-:(Whatever, Whatever) and infix/:(Whatever,Int) are supported

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

2007-01-31 Thread larry
Author: larry Date: Wed Jan 31 10:37:46 2007 New Revision: 13557 Modified: doc/trunk/design/syn/S05.pod Log: Clean up some of the language to avoid confusing automata terminology. Changed token keyword not to terminate token autodeclaration on whitespace, so it's now possible to specify a

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

2007-01-31 Thread larry
Author: larry Date: Wed Jan 31 13:01:12 2007 New Revision: 13558 Modified: doc/trunk/design/syn/S05.pod Log: Made a bunch of declarative/procedural distinctions. Modified: doc/trunk/design/syn/S05.pod == ---