remember to register roles with newly created metaclass
[gitmo/Moo.git] / lib / Moo / Role.pm
index 4055fbc..71ee793 100644 (file)
@@ -22,6 +22,9 @@ sub import {
     })->generate_method($target, $name, \%spec);
     $INFO{$target}{attributes}{$name} = \%spec;
   };
+  if ($INC{'Moo/HandleMoose.pm'}) {
+    Moo::HandleMoose::inject_fake_metaclass_for($target);
+  }
   goto &Role::Tiny::import;
 }
 
@@ -130,3 +133,13 @@ imported by this module.
 
 Declares an attribute for the class to be composed into.  See
 L<Moo/has> for all options.
+
+=head1 AUTHORS
+
+See L<Moo> for authors.
+
+=head1 COPYRIGHT AND LICENSE
+
+See L<Moo> for the copyright and license.
+
+=cut