X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?p=gitmo%2FMouse.git;a=blobdiff_plain;f=lib%2FMouse%2FExporter.pm;h=e44c2565f3c6960307907dca4cb5840bc1d095bf;hp=2ee752bc55e3bbbe9290d97e822b9fcd9135b9d2;hb=57633577acaebd562d9bf8a798bb66f5840d88c7;hpb=c35735177e2a2737f046c811218fc6d406a6f22d diff --git a/lib/Mouse/Exporter.pm b/lib/Mouse/Exporter.pm index 2ee752b..e44c256 100644 --- a/lib/Mouse/Exporter.pm +++ b/lib/Mouse/Exporter.pm @@ -6,14 +6,15 @@ use Carp qw(confess); my %SPEC; -use constant _strict_bits => strict::bits(qw(subs refs vars)); +my $strict_bits; +BEGIN{ $strict_bits = strict::bits(qw(subs refs vars)); } # it must be "require", because Mouse::Util depends on Mouse::Exporter, # which depends on Mouse::Util::import() require Mouse::Util; sub import{ - $^H |= _strict_bits; # strict->import; + $^H |= $strict_bits; # strict->import; ${^WARNING_BITS} |= $warnings::Bits{all}; # warnings->import; return; } @@ -162,7 +163,7 @@ sub do_import { } } - $^H |= _strict_bits; # strict->import; + $^H |= $strict_bits; # strict->import; ${^WARNING_BITS} |= $warnings::Bits{all}; # warnings->import; if($spec->{INIT_META}){