abitkin has asked for the wisdom of the Perl Monks concerning the following question:
# Node: sub new{ my $self = []; $self->[$node::child]=[]; $self->[$node::leaves] = undef; $self->[$node::myDepth] = undef; $self->[$const::getType] = "Node"; # Added/Changed by KIN # trying to limit mem usage # Date: Tuesday, August 06, 2002 @ 10:18 AM if(not($const::LSNmode == 1)){ $self->[$node::nodes] = undef; $self->[$node::bits] = undef; }else{ $self->[$node::lsnBits] = undef; $self->[$node::nodeBits] = undef; $self->[$node::isLSN] = undef; $self->[$node::reBits] = undef; $self->[$node::reNodes] = undef; } bless($self); return $self; } # Leaf: sub new{ my $self = []; $self->[$ptr::weight] = 0; $self->[$ptr::value] = undef; $self->[$const::getType] = "Leaf"; bless($self); return $self; }
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Possible Memory Usage Issues
by dws (Chancellor) on Aug 06, 2002 at 22:36 UTC | |
by abitkin (Monk) on Aug 07, 2002 at 13:50 UTC | |
by dws (Chancellor) on Aug 07, 2002 at 15:50 UTC | |
by abitkin (Monk) on Aug 07, 2002 at 16:45 UTC | |
Re: Possible Memory Usage Issues
by kvale (Monsignor) on Aug 06, 2002 at 22:35 UTC | |
by abitkin (Monk) on Aug 07, 2002 at 13:43 UTC | |
Re: Possible Memory Usage Issues
by perrin (Chancellor) on Aug 07, 2002 at 14:14 UTC | |
by abitkin (Monk) on Aug 07, 2002 at 14:33 UTC |