Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask
 
PerlMonks  

Re^2: Multi-stage flip-flop?

by RonW (Parson)
on Dec 11, 2014 at 16:46 UTC ( [id://1110067]=note: print w/replies, xml ) Need Help??


in reply to Re: Multi-stage flip-flop?
in thread Multi-stage flip-flop?

Can a "bare" regex be used like that? I would have thought it would need quoting.

So maybe:

till ( qr/match0/ => \&doOtherProcessing, qr/match1/ => \&doStage1, )

Replies are listed 'Best First'.
Re^3: Multi-stage flip-flop?
by LanX (Saint) on Dec 11, 2014 at 17:08 UTC
    That's completely different, qr// returns a regex and not the result of a boolean test.

    Cheers Rolf

    (addicted to the Perl Programming Language and ☆☆☆☆ :)

      How else would till control which condition got evaluated?

      If till were actually built in to Perl, it could control control evaluation.

      But, if it was built in, then it could impose scalar context on the conditions with out needing the - in front.

        It doesn't need to know the condition just the result by position.

        I'll post some proof of concept later...

        Asking for built-ins is an illusion...

        Cheers Rolf

        (addicted to the Perl Programming Language and ☆☆☆☆ :)

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others examining the Monastery: (4)
As of 2024-04-25 08:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found