Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: List::Util - Bug in first?

by kyle (Abbot)
on Feb 18, 2008 at 14:14 UTC ( #668554=note: print w/ replies, xml ) Need Help??


in reply to List::Util - Bug in first?

The return value of first is always a scalar. I think it would be a bug to put it in list context as if it's going to return anything other than one thing. You might want it in list context with other things if the result of first will be a member of that list. In that case, returning nothing could ruin the placement of the other items.


Comment on Re: List::Util - Bug in first?
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://668554]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others having an uproarious good time at the Monastery: (6)
As of 2015-07-07 08:13 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (87 votes), past polls