|
|
| Do you know where your variables are? | |
| PerlMonks |
Re: Is map's sub block really being evaluated in list context? wantarray() returns undef..by GrandFather (Cardinal) |
| on Oct 19, 2011 at 19:59 UTC ( #932488=note: print w/ replies, xml ) | Need Help?? |
|
wantarray's documentation says it all really. wantarray is sensitive to the "subroutine or eval" context and is "unspecified in the top level of a file". map isn't a sub or eval so doesn't provide any new context for wantarray.
True laziness is hard work
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||