From: Jesse Luehrs Date: Sat, 6 Feb 2010 23:03:18 +0000 (-0600) Subject: don't initialize classes without a metaclass to anything but CMOP::Class X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=c5934dc3306d11419e92ce984ee508b454f4d022;p=gitmo%2FClass-MOP.git don't initialize classes without a metaclass to anything but CMOP::Class --- diff --git a/lib/Class/MOP/Class.pm b/lib/Class/MOP/Class.pm index 41ed999..e8379bc 100644 --- a/lib/Class/MOP/Class.pm +++ b/lib/Class/MOP/Class.pm @@ -726,7 +726,7 @@ sub find_method_by_name { (defined $method_name && length $method_name) || confess "You must define a method name to find"; foreach my $class ($self->linearized_isa) { - my $method = $self->initialize($class)->get_method($method_name); + my $method = Class::MOP::Class->initialize($class)->get_method($method_name); return $method if defined $method; } return;