Re: More A5/E5 questions

2002-09-09 Thread David Helgason
Damian Conway Wrote: >> [worry #1] >> The hypothetical 'variables' we bind to aren't really variables >> but keys to a hash. >Welcome to Perl 6. Where *no* variable is really a variable, but > all are keys to a hash (which is known as the symbol table) ;-) Ok, you're obviously right. But $0

Re: More A5/E5 questions

2002-09-09 Thread David Helgason
Jonathan Scott Duff wrote: > Question #3: > > Related to question #2, if I didn't use hypotheticals, how would I > access the Nth match of a repitition? For instance, in E5, there's an > example that looks like this: > > rule file { ^ @adonises := * $ } > > If I didn't have the hypoth

Re: Suggestion for perl 6 regex syntax

2002-09-09 Thread David Helgason
Yeay! Golf... Adam D. Lopresto wrote: [...golf...] > /^([+-]?)(?=\d|\.\d)\d*(\.\d*)?([Ee]([+-]?\d+))?$/ #50 chars [...more golf...] > Of course, that's because we use perl6's strengths. > > :i/^(+|-)?(\d*[\.\d*]?)<($2=~/./)>[E([+|-]?\d+)]?$/ #51 Clever! But If we are allowed to