Subject: | importing UNIVERSAL::isa breaks some Exporter modules |
I'm not quite sure *how* this is accomplished, but using this module
along with some internal code at my job causes bizarre and fatal
compile-time errors (perl 5.6.1, Linux). I traced the problem to the
'"use UNIVERSAL 'isa'" statement: replacing it with equivalent typeglob
assignment, as suggested in the UNIVERSAL perldocs, resolved the
problem. Trivial patch attached.
If you're curious about the core problem, it appears to turn up in
circular-import situations, but I confess I haven't looked all that
closely at the mechanism. (Meant to, but haven't had time.)
Subject: | universal_patch.txt |
--- /usr/people/bwarf/.cpan/build/Data-JavaScript-Anon-0.6/lib/Data/JavaScript/Anon.pm 2005-07-26 04:48:34.000000000 -0400
+++ /usr/people/bwarf/lib/site_perl/5.6.1/Data/JavaScript/Anon.pm 2005-08-11 18:04:51.000000000 -0400
@@ -5,8 +5,7 @@
# from Perl to JavaScript.
use strict;
-use UNIVERSAL 'isa';
-
+*isa = \&UNIVERSAL::isa;
use vars qw{$VERSION $errstr $RE_NUMERIC $RE_NUMERIC_HASHKEY %KEYWORD};
BEGIN {
$VERSION = '0.6';