Welcome to the Monastery | |
PerlMonks |
Re: syntax error with map in list contextby dave0 (Friar) |
on Nov 20, 2005 at 13:38 UTC ( [id://510244]=note: print w/replies, xml ) | Need Help?? |
It's a known issue with Perl guessing wrong on the meaning of the initial
{. See the Perldoc for map, in the paragraph beginning:
"{" starts both hash references and blocks, so "map { ..." could be either the start of map BLOCK LIST or map EXPR, LIST. There are examples of how to avoid the problem in that doc, but my suggestion would be:
In Section
Seekers of Perl Wisdom
|
|