What is the standard way to optimise mutual recursion in F#/Scala?
These languages do not support mutually recursive functions optimization 'natively', so I guess it must be trampoline or.. heh.. rewriting as a loop) Do I miss something? UPDATE: It seems that I did lie about FSharp, but I just didn't see an example of mutual tail-calls while googling First of all, F# supports mutually recursive functions natively, because it can benefit from the tailcall instruction that's available in the .NET IL ( MSDN ). However, this is a bit tricky and may not work on some alternative implementations of .NET (e.g. Compact Frameworks), so you may sometimes need to deal