Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: Interpolation of capture buffers not working when regex stored in variable

by ikegami (Pope)
on Jun 05, 2013 at 20:14 UTC ( #1037297=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my $p = "$2$1";       # my $p = $2.$1;
                          # Doesn't change the value of $2 or $1.
    
  2. or download this
    my $p = "$ARGV[0]";   # my $p = "".$ARGV[0];
                          # Doesn't change the value of $ARGV[0].
    
  3. or download this
    use String::Interpolate qw( interpolate);
    
    ...
    my $t = $ARGV[0];
    
    my $p = interpolate($t);
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (11)
As of 2014-12-22 23:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (133 votes), past polls