Recursively traverse linked list -- help!
phr-n2002a at nightsong.com
Thu Feb 21 07:12:01 CET 2002
"Terry Reedy" <tjreedy at home.com> writes:
> > Oh yes, you're correct. However, the tail call should still be
> > optimized, compiled as an indirect jump to f.
> I can accept 'maybe could' (see below) but 'should'? What sense of
> shouldness are you using?
The normative sense of what one can expect of a compiler that implements
tail recursion optimization. That's separate from the question of
whether compilers should be expected to implement TRO. For Scheme,
it's required and you can expect it. For Python, it's not required
and you shouldn't expect it. OK?
More information about the Python-list