module name. For some reason, this fixes a bug that tokuhirom found in
Moose (t/030_roles/031_roles_applied_in_create.t), which seemed to
have something to do with load order of the various roles. Go figure.
# if the class is not already loaded in the symbol table..
unless (is_class_loaded($class)) {
# require it
- my $file = $class . '.pm';
- $file =~ s{::}{/}g;
- my $e = do { local $@; eval { require($file) }; $@ };
+ my $e = do { local $@; eval "require $class"; $@ };
confess "Could not load class ($class) because : $e" if $e;
}