|
|
|
good chemistry is complicated, and a little bit messy -LW |
|
| PerlMonks |
Re: Finding match offsets of named captures in 5.10 regexby JavaFan (Canon) |
| on Sep 27, 2008 at 21:11 UTC ( #714060=note: print w/ replies, xml ) | Need Help?? |
|
Every named capture is numbered as well. So if you have a capture called 'foo', and it's the third capture, you find the offsets in $- [2] and $+ [2]. There isn't a hash with the indexes.
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||