my ($v) = $real_ver =~ /([1-9])/;
$v = "v$v";
- last if $v eq CURRENT_V;
+ last if $v eq CURRENT_V || $real_ver =~ /^0\.04999/;
if (not %{ $self->naming }) {
warn <<"EOF" unless $ENV{SCHEMA_LOADER_BACKCOMPAT};
if ($self->dynamic) { # load the class too
# kill redefined warnings
+ my $warn_handler = $SIG{__WARN__} || sub { warn @_ };
local $SIG{__WARN__} = sub {
- warn @_ unless $_[0] =~ /^Subroutine \S+ redefined/;
+ $warn_handler->(@_)
+ unless $_[0] =~ /^Subroutine \S+ redefined/;
};
do $real_inc_path;
die $@ if $@;
new name of the Result.
EOF
# kill redefined warnings
+ my $warn_handler = $SIG{__WARN__} || sub { warn @_ };
local $SIG{__WARN__} = sub {
- warn @_ unless $_[0] =~ /^Subroutine \S+ redefined/;
+ $warn_handler->(@_)
+ unless $_[0] =~ /^Subroutine \S+ redefined/;
};
my $code = do {
local ($/, @ARGV) = (undef, $old_real_inc_path); <>
delete $INC{ $class_path };
# kill redefined warnings
+ my $warn_handler = $SIG{__WARN__} || sub { warn @_ };
local $SIG{__WARN__} = sub {
- warn @_ unless $_[0] =~ /^Subroutine \S+ redefined/;
+ $warn_handler->(@_)
+ unless $_[0] =~ /^Subroutine \S+ redefined/;
};
-
eval "require $class;";
}