in reply to Re: Regexes: finding ALL matches (including overlap)
in thread Regexes: finding ALL matches (including overlap)
So I just read through perlre and I couldn't find something: how does one include a (code-based) conditional expression in a regex, analogous to actions in P::RD? Is it even possible? If so, then one could not only find the last match (which may differ slightly from reversing the result of a reversed regex):
but also the (say) tenth match."abcdef" =~ /(..*..*.)(?{$last = $^N})(?!)/; print "[$last]\n"; ## "[def]"
Another solution to my problem would be possible if P::RD had non-greedy matches. Is it likely that this will be implemented soon? I guess I could try hacking on it myself.
P.S.: Has anyone ever used customre? Super Search gave back only one result ...
|
|---|