Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re^2: While two conditions

by welle (Beadle)
on May 01, 2012 at 14:17 UTC ( #968266=note: print w/ replies, xml ) Need Help??


in reply to Re: While two conditions
in thread While two conditions

It looks like it could be something for me, BUT - excuse my ignorance - waht kind of sintax is this:

my $query = qr{ (?<M>monk) (?(<M>)(?{do_something_different()})) | (?<P>perl) (?(<P>)(?{do_something()})) }x;

With perl 5.8.9 it just doesn't work


Comment on Re^2: While two conditions
Download Code
Replies are listed 'Best First'.
Re^3: While two conditions
by Anonymous Monk on May 02, 2012 at 06:40 UTC

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others chanting in the Monastery: (5)
As of 2015-07-30 02:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (269 votes), past polls