Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re^4: Regexp not capturing in named subrules (first)

by tye (Sage)
on Sep 16, 2009 at 17:20 UTC ( [id://795671]=note: print w/replies, xml ) Need Help??


in reply to Re^3: Regexp not capturing in named subrules
in thread Regexp not capturing in named subrules

For clarity, the regex expands to the equivalent of:

re = %r{ (?: (?<thing>.­+) ){0} (?<thing>.­+) }

So, yes, (?<thing>.+) did match. It is just that the first instance didn't match. In Perl, %+ only records the captures of the first instance.

- tye        

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://795671]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2024-04-19 09:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found