in reply to Re^9: Specializing Functions with Currying
in thread Specializing Functions with Currying
... it was that recursion in Perl is crazy inefficient, ...
Is it really? I mean, its certainly not as efficient as the equivalent iterative code. And I know that subroutine calls have a non-trivial overhead (setting up lexical scope and all), but being that perl does not tie itself to the C-stack like some other langauges do (*cough* Python *cough*) I would think that it wouldn't really be all that inefficient. Of course, I have never benchmarked it, so who knows.
... and to use it just because its "functional" is kind of silly ...
But if we can't get silly with Perl at 7 o'clock (EST) on a Friday night, then what kind of world is this! ;-P
about tail-recursion, which is an optimization that Perl doesn't support (for some reason, I honesetly don't have a clue why)
I don't know why either, I once looked into trying to "implement" it with the B:: modules. But once was all it took for me to to decide that wouldn't work.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^11: Specializing Functions with Currying
by jryan (Vicar) on Aug 07, 2004 at 00:08 UTC | |
by stvn (Monsignor) on Aug 07, 2004 at 00:25 UTC | |
by itub (Priest) on Aug 07, 2004 at 02:35 UTC | |
by stvn (Monsignor) on Aug 07, 2004 at 03:11 UTC | |
by diotalevi (Canon) on Aug 07, 2004 at 03:23 UTC |