some style tweaks to t0m's change to the metaclass compat fixing code.
[gitmo/Moose.git] / lib / Moose / Meta / Role.pm
index dcca38f..65de5aa 100644 (file)
@@ -8,8 +8,9 @@ use metaclass;
 use Scalar::Util 'blessed';
 use Carp         'confess';
 use Sub::Name    'subname';
+use Devel::GlobalDestruction 'in_global_destruction';
 
-our $VERSION   = '0.76';
+our $VERSION   = '0.77';
 $VERSION = eval $VERSION;
 our $AUTHORITY = 'cpan:STEVAN';
 
@@ -555,7 +556,7 @@ sub create {
     sub DESTROY {
         my $self = shift;
 
-        return if Class::MOP::in_global_destruction(); # it'll happen soon anyway and this just makes things more complicated
+        return if in_global_destruction(); # it'll happen soon anyway and this just makes things more complicated
 
         no warnings 'uninitialized';
         return unless $self->name =~ /^$ANON_ROLE_PREFIX/;