James Edward Gray II wrote:

Fact: This has nothing to do with ANY variables, it is the way warn() is designed.

Trivia:


Did you know that $! does NOT contain an error string. It contains the error *number*. The only reason you see a error sting is that it has an overloaded stringification operator that calls strerror() on the numeric value that it contains.

# assuming the file 'foo' does not exist in current directory.

perl -e 'open FOO,"foo" or print $!+0'
=> 2

perl -MPOSIX -e 'open FOO,"foo";print strerror $!+0'
=> No such file or directory

Randy.

--
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