Subject: | Scoping issue. |
Hello all.
My understanding is that running test.pl here should result in an
exception for the failed open:
<test.pl>
use autodie;
use FOO;
<FOO.pm>
use autodie;
open(my $fh, 'NO SUCH FILE');
1;
But it exits quietly.
Though it shouldn't be necessary, the above can be convinced to die by
adding a package declaration to FOO.pm:
<FOO.pm>
package ANYTHING_BUT_main;
use autodie;
open(my $fh, 'NO SUCH FILE');
1;
Perhaps there's some kind of global caching going on that's at odds
with autodie's function as a lexical pragma?
autodie 2.10
perl 5.12.1 (Strawberry)
Windows 7
Thanks for your consideration, and for the great module (and sorry if
my assumptions are bad).