Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^2: Greedy regexp matching: differences between man page and implementation?

by perldeveloper (Scribe)
on Jul 08, 2004 at 13:47 UTC ( #372796=note: print w/replies, xml ) Need Help??


in reply to Re: Greedy regexp matching: differences between man page and implementation?
in thread Greedy regexp matching: differences between man page and implementation?

This is an even more obvious:
$_='abcdefgh'; /^(a|abcdefg)(h|bc)/; print "[$1] [$2]\n";
It prints [a] [bc]. The regexp engine clearly doesn't run through all possible combinations within (..|..|..) patterns.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (1)
As of 2023-03-21 03:37 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Which type of climate do you prefer to live in?






    Results (59 votes). Check out past polls.

    Notices?