I was wondering what the scope of perlvars (ie. $! and $?) are across
modules?
Here's my situation:
In module:
open file || return -1;
In script:
Can I use $! here? and will it contain the reason open didn't open (if it
didn't) in the module?
Would I need to export the $! from the module
On Jul 18, Nikola Janceski said:
I was wondering what the scope of perlvars (ie. $! and $?) are across
modules?
Those variables are true globals. They are seen everwhere.
In module:
open file || return -1;
In script:
Can I use $! here? and will it contain the reason open didn't open