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

Re: Re: is the use of map in a void context deprecated ?

by liz (Monsignor)
on Oct 05, 2003 at 18:57 UTC ( #296753=note: print w/ replies, xml ) Need Help??


in reply to Re: is the use of map in a void context deprecated ?
in thread is the use of map in a void context deprecated ?

...I seem to recall that map was just rewritten to check for void context and avoid the extra work if possible.

That is correct. And it's in Perl 5.8.1! From the 5.8.1. perldelta:

"map" in void context is no longer expensive. "map" is now context aware, and will not construct a list if called in void context.

Liz


Comment on Re: Re: is the use of map in a void context deprecated ?
Re: Re: Re: is the use of map in a void context deprecated ?
by arno (Scribe) on Oct 05, 2003 at 19:22 UTC
    I didn't know perldelta('s), we can learn a lot from it ...
    Let me sharing this :
    "Switch", by Damian Conway, has been added. Just by saying :
    use Switch;
    Fore more information on this module :
    $ perldoc Switch

    Thanks Liz and Zaxo for answering,

    Arnaud
      It's just a source filter though, and while it tries really hard to parse Perl, only perl really can. F.ex, I (only accidentally) discovered it was causing a spurious problem for someone else a while ago that seemed to be completely unrelated.

      Makeshifts last the longest.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (5)
As of 2014-12-19 02:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (70 votes), past polls