Use select
In your module
package Whatever; sub whatever { my $filehandle = select; print $filehandle ...; }
In your program
use Whatever; open my($fh)...; select $fh; whatever('whatever');
In reply to Re: Globalize Filehandles and Visibility in Packages? (dont)
by Anonymous Monk
in thread Globalize Filehandles and Visibility in Packages?
by smknjoe
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |