in reply to Re^2: Possible useless use of map
in thread Possible useless use of map

I think it's always been a list of values on the stack.

I think they (c/c++ programmers) call that an array :)

Replies are listed 'Best First'.
Re^4: Possible useless use of map
by Marshall (Canon) on Mar 20, 2010 at 06:56 UTC
    Nope. C doesn't return arrays on the stack and neither does Perl.

    I recommend: "Advanced Perl Programming" by Srinivsan as a good reference for those interested about Perl internals.

      Who said return? Besides, the memory penalty wasnt a memory leak, just memory that was allocated needlessly, then released.
        Once Perl has some memory, it never gives it back to the OS. Perl can reuse its memory and it is pretty smart about that. Writing to and using more memory is a penalty as that takes CPU Mips even if it doesn't take disk space.