Skip class unload stuff in global destruction
[gitmo/Mouse.git] / lib / Mouse / Meta / Module.pm
index 93b6f68..8a4ccb9 100755 (executable)
@@ -265,6 +265,8 @@ sub get_method_list {
     sub DESTROY{
         my($self) = @_;
 
+        return if $Mouse::Util::in_global_destruction;
+
         my $serial_id = $self->{anon_serial_id};
 
         return if !$serial_id;