Larry Wall writes: > On Fri, Mar 26, 2004 at 09:41:23AM -0700, Luke Palmer wrote: > : Is @{$foo} going away? More specifically, how do I write that map if > : $baz is some more complex expression, and I don't want to use * (say I > : want to adhere if map decides to change its signature to take a real > : array)? > > @{EXPR} still works.
Okay, now that that's all cleared up, time to propose something. When writing Perl 5, I always find myself writing @{ more often than @$. Maybe it's just a bad habit that I don't tend to use a lot of intermediate variables. I propose that the precedence of the of the dereferencing sigils be loosened so I don't have to write those pesky squigglies all the time. What used to be: for my $i (@{$foo->{bar}[$ind]}) { } Can now be: for @$foo{bar}[$ind] -> $i {...} It doesn't feel quite right, but that's probably because I've written it the other way so much. The only reason to keep it around is if you wanted to use the archaic: @$foo[2]; Or if you wanted to call methods on the array: @$foo.sort; But since you can call methods on a reference and get them delegated anyway, that's not a problem. And as for the first one, well, who needs that when they can just leave off the @ altogether? Luke