From: Chris Prather Date: Thu, 30 Apr 2009 04:29:06 +0000 (-0400) Subject: 05:27 <@autarch> just import them in both Moose & CMOP X-Git-Tag: 0.77~9 X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=ae736ff4ae42914b86c4debc273efdde0c448536;p=gitmo%2FMoose.git 05:27 <@autarch> just import them in both Moose & CMOP --- diff --git a/lib/Moose/Object.pm b/lib/Moose/Object.pm index f33901a..974908d 100644 --- a/lib/Moose/Object.pm +++ b/lib/Moose/Object.pm @@ -5,7 +5,7 @@ use strict; use warnings; use Scalar::Util; -use Devel::GlobalDestruction (); +use Devel::GlobalDestruction qw(in_global_destruction); use if ( not our $__mx_is_compiled ), 'Moose::Meta::Class'; use if ( not our $__mx_is_compiled ), metaclass => 'Moose::Meta::Class'; @@ -82,12 +82,12 @@ sub DESTROY { # localize the $@ ... local $@; # run DEMOLISHALL ourselves, ... - $_[0]->DEMOLISHALL(Devel::GlobalDestruction::in_global_destruction); + $_[0]->DEMOLISHALL(in_global_destruction); # and return ... return; } # otherwise it is normal destruction - $_[0]->DEMOLISHALL(Devel::GlobalDestruction::in_global_destruction); + $_[0]->DEMOLISHALL(in_global_destruction); } # support for UNIVERSAL::DOES ...