my @a = qw(aaa bbb); my $r = \$a[0]; @a = (); print $$r; #### sub f { my $x = ...; return $x }