|
|
||||
|
Re: Tail recursive functions
by
Anonymous
I think it would be very useful to extend this approach to handle not only a function calling itself as the last thing done but also a function calling any other function as the last thing done.
The only change from a normal call is to provide as return address to the function we are calling our own return address (that is the address of the point after we were called by our caller).
This, of course, solves also the problem of indirect (circular) recursion.
Dimitre Novatchev
|
Search
Recent Comments
Recent Articles
Month Archive
|
|||