B
brian.haines
This code:
my @sref = @{$softwareListRef};
print Dumper(@sref);
for (my $i = 0; $i<@sref ; $i++) {
my $sn = $sref[$i];
print Dumper($sn);
Generates this output:
$VAR1 = [
'autoTestSoftware001',
'autoTestSoftware050'
];
$VAR1 = [
'autoTestSoftware001',
'autoTestSoftware050'
];
Note that the array @sref is properly de-referenced and printed. Then,
inexplicably, the array item is selected by index and when printed, is
equal to the original array. Foreach does the same thing. What's going
on?
my @sref = @{$softwareListRef};
print Dumper(@sref);
for (my $i = 0; $i<@sref ; $i++) {
my $sn = $sref[$i];
print Dumper($sn);
Generates this output:
$VAR1 = [
'autoTestSoftware001',
'autoTestSoftware050'
];
$VAR1 = [
'autoTestSoftware001',
'autoTestSoftware050'
];
Note that the array @sref is properly de-referenced and printed. Then,
inexplicably, the array item is selected by index and when printed, is
equal to the original array. Foreach does the same thing. What's going
on?