Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: using a variable name for a filehandle

by ateague (Monk)
on Sep 18, 2015 at 15:37 UTC ( [id://1142441]=note: print w/replies, xml ) Need Help??


in reply to using a variable name for a filehandle

Just to expand what poj said:
If you're storing handles in an array or hash, <...> you will have to use a block returning the filehandle value instead

Before:
print $introsh{$intro} $line;

After:
print {$introsh{$intro}} $line;

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others meditating upon the Monastery: (3)
As of 2024-04-24 15:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found