Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Is map's sub block really being evaluated in list context? wantarray() returns undef..

by GrandFather (Sage)
on Oct 19, 2011 at 19:59 UTC ( #932488=note: print w/replies, xml ) Need Help??


in reply to Is map's sub block really being evaluated in list context? wantarray() returns undef..

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
  • Comment on Re: Is map's sub block really being evaluated in list context? wantarray() returns undef..

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://932488]
help
Chatterbox?
[marto]: good morning all

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (7)
As of 2017-07-26 08:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    I came, I saw, I ...
























    Results (385 votes). Check out past polls.