Microsoft's new F# programming language provides the powerful combination of functional programming (first-class lexical closures and tail calls) with an efficient concurrent garbage collector that makes it easy to leverage multicores.
OCaml, Haskell, Erlang and all free Lisp and Scheme implementations that I know of do not have concurr...
I was reading about Clojure and found a discussion about Java not supporting tail calls, in the current version, and that people were throwing exceptions to simulate tail calling in the JVM, anyways it sounds like people are doing some crazy stuff out there. So this got me wondering about C#'s tail calling, same issues?
...
According to answers to that question:
Which, if any, C++ compilers do tail-recursion optimization?
it seems, that compiler should do tail-recursion optimization.
But I've tried proposed options and it seems that compiler can't do this optimization in case of template functions. Could it be fixed somehow?
...
How can I implement tail calls in a custom virtual machine?
I know that I need to pop off the original function's local stack, then it's arguments, then push on the new arguments. But, if I pop off the function's local stack, how am I supposed to push on the new arguments? They've just been popped off the stack.
...
Sometimes it's simple enough (if the self call is the last statement, it's tail recursion), but there are still cases that confuse me. A professor told me that "if there's no instruction to execute after the self-call, it's tail recursion". How about these examples (disregard the fact that they don't make much sense) :
a) This one sho...
I'be seen a few questions regarding missing tail call optimization in C# supposedly making the language ill suited for recursive algorithm implementations. this, however,begs the question, how can we do tail call optimizations and still provide sensible stack traces when exceptions are raised or when reflection may be used to inspect the...