Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: =~ doesn't work with Quantum::Superpositions

by DrManhattan (Chaplain)
on Apr 20, 2003 at 15:57 UTC ( [id://251834]=note: print w/replies, xml ) Need Help??


in reply to =~ doesn't work with Quantum::Superpositions

Looks like eq is overloaded, but =~ is not. When you make a regex comparison, you're just getting a regex match against the stringified object (in this case "any(a,b)") on the LHS.
use Quantum::Superpositions; # Create a disjunction of 'a' and 'b'. $dis = any( 'a', 'b' ); $dis =~ /.*/ && print $&;
Prints "any(a,b)"

-Matt

Log In?
Username:
Password:

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

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

    No recent polls found