Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: dereferencing file handles

by bwana147 (Pilgrim)
on Sep 03, 2001 at 11:48 UTC ( [id://109826]=note: print w/replies, xml ) Need Help??


in reply to dereferencing file handles

The Cookbook (I haven't got it at hand, so I can't quote) says that a filehandle in a print statement must be a typeglob or a real scalar variable (not an indexed element of a hash/array). You can work around like you did or:

print {$self->{_handle}} "$location, $message. \n";

I guess the gurus familiar with Perl's guts can explain why. I can't.

--bwana147

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (7)
As of 2024-04-19 09:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found