]> git.donarmstrong.com Git - class_modular.git/.git/blobdiff - lib/Class/Modular.pm
* Added svn:keyword Id LastChangedRevision
[class_modular.git/.git] / lib / Class / Modular.pm
index 7977e7e2ca44ccc0a88a6f37913d933bd2a15cf3..4bd2d15a0be7987472ec552c28feba31ea8b1a49 100644 (file)
@@ -2,7 +2,7 @@
 # under the terms of the GPL version 2, or any later version. See the
 # file README and COPYING for more information. Copyright 2003 by Don
 # Armstrong <don@donarmstrong.com>.
-# $Id: Modular.pm,v 1.8 2003/12/09 02:00:10 don Exp $
+# $Id$
 
 package Class::Modular;
 
@@ -50,10 +50,11 @@ use vars qw($VERSION $DEBUG);
 
 use Carp;
 
-use Data::Copy qw(deep_copy); # Used for deep copying objects
+use Storable qw(dclone); # Used for deep copying objects
 
 BEGIN{
-     ($VERSION) = q$Revision: 1.8 $ =~ /\$Revision:\s+([^\s+])/;
+     $VERSION = '0.1';
+     ($REVISION) = q$LastChangedRevision$ =~ /\$LastChangedRevision:\s+([^\s+])/;
      $DEBUG = 0 unless defined $DEBUG;
 }
 
@@ -245,8 +246,8 @@ sub clone {
      bless $clone, ref($self);
 
      # copy data structures at this level
-     $clone->{_methodhash} = deep_copy($self->{_methodhash});
-     $clone->{_subclasses} = deep_copy($self->{_subclasses});
+     $clone->{_methodhash} = dclone($self->{_methodhash});
+     $clone->{_subclasses} = dclone($self->{_subclasses});
 
      foreach my $subclass (keys %{$self->{_subclasses}}) {
          # use eval to try and call the subclasses _clone method.