fix the failing test, only call ->meta on a linearized isa member if ->can('meta')
Yuval Kogman [Mon, 16 Jun 2008 22:16:26 +0000 (22:16 +0000)]
lib/Mouse/Meta/Attribute.pm

index 733c129..9176bd0 100644 (file)
@@ -289,7 +289,7 @@ sub get_parent_args {
     my $name  = shift;
 
     for my $super ($class->meta->linearized_isa) {
-        my $super_attr = $super->meta->get_attribute($name)
+        my $super_attr = $super->can("meta") && $super->meta->get_attribute($name)
             or next;
         return %{ $super_attr->_create_args };
     }