Disable foreign class warnings (PERL_MOUSE_STRICT will enable this)
Fuji, Goro [Thu, 27 Jan 2011 00:17:50 +0000 (09:17 +0900)]
lib/Mouse/Meta/Class.pm

index f278f5a..ae611ec 100644 (file)
@@ -93,9 +93,11 @@ sub verify_superclass {
 
 sub inherit_from_foreign_class {
     my($class, $super) = @_;
-    Carp::carp("You inherit from non-Mouse class ($super),"
-        . " but it is unlikely to work correctly."
-        . " Please consider using MouseX::Foreign");
+    if($ENV{PERL_MOUSE_STRICT}) {
+        Carp::carp("You inherit from non-Mouse class ($super),"
+            . " but it is unlikely to work correctly."
+            . " Please consider using MouseX::Foreign");
+    }
     return;
 }