Subject: | append_arrays() shouldn't eat up arrays referred to by input parameters |
Date: | Wed, 20 Dec 2006 13:52:56 -0800 |
To: | <bug-Statistics-LSNoHistory [...] rt.cpan.org> |
From: | "Sean Mostafavi" <sean.mostafavi [...] isilon.com> |
Hello,
I was pulling my hair out trying to figure out why the
following produced an error at line 347:
@x = 1 .. 100;
@y = 1 .. 100;
my $reg1 = Statistics::LSNoHistory->new();
my $reg2 = Statistics::LSNoHistory->new();
$reg1->append_arrays(\@x, \@y);
$reg2->append_arrays(\@x, \@y);
After the first append_arrays call, @x will be empty. Something other
than shift should probably be used in append_arrays().
--
Sean Mostafavi