>So, 1. from within perl.script, how can one tell if the input stream is
>coming from STDIN or a file that was opened by <>?

Use select

>2. If input stream is not coming from STDIN, but a file, how can one
>tell which file is the current file (assuming multiple files were
>specified on the command line)?

My solution is the hard way.  Open the files yourself and use the
respective filenames as their filehandles.
That is:
open($foo, "< $foo") or die "Could not open $foo: $!\n";


__________________

William Ampeh (x3939)
Federal Reserve Board


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to