Mark-Jason Dominus wrote: > > > > $count = () = $string =~ /pattern/g; > > > > Which I find cute as a demonstration of the Perl's context concept, > > but ugly as hell from usability viewpoint. > > I'd really like to see an RFC that looks into making the following > features more orthogonal: > > 1. Return the number of matches > > 2. Iterate over each match in sequence > > 3. Return list of all matches > > 4. Return a list of backreferences Please see RFC 164. It can handle all of 1-3. v2, out hopefully by the end of tomorrow, will be about 3 times the size and much more explicit about these capabilities. It will also include a number of backwards-compatible syntaxes. -NateThread Previous | Thread Next