use warnings;
require 5.006_000;
+# Keep this < 1.00, so people can tell the fake
+# mro.pm from the real one
our $VERSION = '0.01';
BEGIN {
*mro::method_changed_in = \&__method_changed_in;
*mro::invalidate_all_method_caches
= \&__invalidate_all_method_caches;
+ $mro::VERSION = $VERSION;
+ $INC{'mro.pm'} = 'Faked by MRO::Compat';
}
# Provide no-op Class::C3::.*initialize() funcs for 5.9.5+
die q{Invalid mro type "$type"};
}
- # In the dfs case, check whether we need to
- # undo C3
+ # In the dfs case, check whether we need to undo C3
if(defined $Class::C3::MRO{$classname}) {
Class::C3::_remove_method_dispatch_table($classname);
}
my $classname = shift;
die "mro::get_isarev requires a classname" if !$classname;
- sort @{__get_isarev_recurse($classname, __get_all_pkgs_with_isas(), 0)};
+ @{__get_isarev_recurse($classname, __get_all_pkgs_with_isas(), 0)};
}
=head2 mro::is_universal($classname)
my $classname = shift;
die "mro::is_universal requires a classname" if !$classname;
- my $lin = __get_linear_isa($classname);
+ my $lin = __get_linear_isa('UNIVERSAL');
foreach (@$lin) {
return 1 if $classname eq $_;
}