\@{ [map { $_ => 'fish' } qw(one two red blue)] }
Well, that works but it's a bit wasteful: first you're creating a arrayref with [], then you're dereferencing it with @{}, and then taking a reference to that again with \. It's easier to just use one set of []'s like 1nickt showed (although you may not have seen that yet since it was part of a large ninja edit).
In reply to Re^3: Syntax for casting map to a hash or an array
by haukex
in thread Syntax for casting map to a hash or an array
by cbeckley
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |