| |
| | Tail recursion - Wikipedia, the free encyclopedia |
 | | When a function is called, the computer must "remember" the place it was called from, the return address, so that it can return to that location with the result once the call is complete. |
 | | Since having a complete call graph is a daunting task for compilers, a mere tail call is usually referred to as being tail recursive. |
 | | Using a trampoline for all function calls is rather more expensive than the normal C function call, so at least one Scheme compiler, Chicken, uses a technique first described by Henry Baker from an unpublished suggestion by Andrew Appel, in which normal C calls are used but the stack size is checked before every call. |
| en.wikipedia.org /wiki/Tail_call_optimization (1317 words) |
|