http://qs321.pair.com?node_id=1082247


in reply to Re^4: map {} list or do {} for list?
in thread map {} list or do {} for list?

Sorry, I didn't mean to imply that it wasn't optimized away.

I meant that when reading the code, map says "Hey! Pay attention to the return values of this code block, we're making a list of them."

Replies are listed 'Best First'.
Re^6: map {} list or do {} for list?
by jethro (Monsignor) on Apr 15, 2014 at 09:30 UTC

    Well, the same could be said of "$i++;'. In other words, if god had not meant us to throw away results, he wouldn't have given us void context ;-)