![]() |
|
Pathologically Eclectic Rubbish Lister | |
PerlMonks |
comment on |
( #3333=superdoc: print w/replies, xml ) | Need Help?? |
It was golfing exercise, where I tried everything possible presumably correct from language spec POV as I see it, be it sketchy or not. In the end I didn't need @-, so no problem at all, thank you, just curiosity. Perhaps I know less about regular expressions than I thought. Consistent behaviour would be $#- and $#+ both the same and either 0 or 2 here. And all three $1, $+, $^N ending up the same here, also. It's not what I observe. Can you explain debug output, why the Matching REx "(?=(a))" against "a"and then SUCCEED: subpattern success...are mentioned twice? Same with perl -MRegexp::Debugger -e '$_="a";s/(?=(a))/b/g', I hit Enter too many times, why are steps 0..7 repeated twice? In reply to Re^2: Global match and capture group in look-ahead == under-populated "@-"?
by Anonymous Monk
|
|