Beefy Boxes and Bandwidth Generously Provided by pair Networks
Come for the quick hacks, stay for the epiphanies.
 
PerlMonks  

Re^3: Dereferencing undef as an array: Bug or WAD?

by ChemBoy (Priest)
on Jun 04, 2008 at 15:06 UTC ( [id://690160] : note . print w/replies, xml ) Need Help??


in reply to Re^2: Dereferencing undef as an array: Bug or WAD?
in thread Dereferencing undef as an array: Bug or WAD?

It does persist—you've autovivified $r as a reference to an array, but that array is still empty:

% perl -Mstrict -wle 'my $r = undef; map ++$_, @$r; print $r;' ARRAY(0x10116180)