Hi,
when installing a module which uses the 'our' pragma,
the $VERSION cannot be evaled on systems with Perl 5.005.
This patch tries to warn the user.
Maybe you have a better idea how to do it.
Regards
Roland
#-------------------------------------------------------
--- MM_Unix.pm_1.34 Tue Aug 27 03:17:54 2002
+++ MM_Unix.pm Sun Oct 13 14:42:50 2002
@@ -2939,7 +2939,13 @@
};
local $^W = 0;
$result = eval($eval);
- warn "Could not eval '$eval' in $parsefile: $@" if $@;
+ if ($@) {
+ warn "Could not eval '$eval' in $parsefile: $@";
+ if ( $] < 5.006 and /\bour\b/ ) {
+ print "It seems that your module uses the pragma 'our'.\n";
+ print "This is not valid in Perl $]. Please upgrade to at
+least 5.006.\n"
+ }
+ }
last;
}
close FH;
#-------------------------------------------------------