5 ms·
Tail call optimisation in F# ?
by glutamate 12y ago
Tail call optimisation in F# ?
- saosebastiao 12y agoWait...mono doesn't do tail call optimization with f#???
- glutamate 12y agoIt is (or was) complicated, you could stack overflow on two mutually recursive functions or tail calling inside continuations.
- saosebastiao 12y agoI'm getting constant memory on this (mono v3.12.1) let rec beep x = if x = 0 then x else boop (x - 1) and boop y = if y = 0 then y else beep (y - 1) let main argv = printfn "%A" (beep 999999999) 0
- profquail 12y agoThose are mutually recursive functions, but they're not using continuations.