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

Re: matching constants within a regular expression?

by Paladin (Vicar)
on Mar 10, 2004 at 23:00 UTC ( [id://335649]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $var = "foo @{[ sub() ]} baz";  
    # Note: This calls the sub in list context, so may have a 
    # different effect than if called in scalar context.  Use 
    # ${ \sub() } for scalar context.
    
  2. or download this
    print "attribute 0=\t$1\n" if m/@{[ATTRIBUTE_0]}='(.*)'/;
    

Log In?
Username:
Password:

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

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

    No recent polls found