From: Fuji, Goro Date: Thu, 27 Jan 2011 00:17:50 +0000 (+0900) Subject: Disable foreign class warnings (PERL_MOUSE_STRICT will enable this) X-Git-Tag: 0.89~1 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=e639528a8218de3f63aa0bc19a137a20ad1edf63;p=gitmo%2FMouse.git Disable foreign class warnings (PERL_MOUSE_STRICT will enable this) --- diff --git a/lib/Mouse/Meta/Class.pm b/lib/Mouse/Meta/Class.pm index f278f5a..ae611ec 100644 --- a/lib/Mouse/Meta/Class.pm +++ b/lib/Mouse/Meta/Class.pm @@ -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; }