in reply to Passing an array back from a subroutine
use Data::Dumper; if ($ff1) {my @a_ff1 = &GetRow("$ff1"); print Dumper(\@a_ff1)};
This works as expected for me. Start with this, then keep adding code until the problem arises:
use strict; use warnings; use Data::Dumper; my @a_ff1 = &GetRow("foo"); print Dumper(\@a_ff1); sub GetRow { my @ary = 0 .. 3; return @ary; } __END__ $VAR1 = [ 0, 1, 2, 3 ];
See also Basic debugging checklist
|
|---|