Apologies, I haven't confirmed this myself but it looks credible.
Would love to know if this is easily addressable since I'm getting ready to put QIO in place as the main evaluation context in a fairly large application, with one primary driver being stack safety.
From this discussion thread - https://functionalprogramming.slack.com/archives/C7BBY9A95/p1604439126428300?thread_ts=1603574914.302900&cid=C7BBY9A95
it appears the following code would blow the call stack
it('should be stack safe - recursion case', () => {
function a(n: number): any {
if (n === 1) {
return QIO.resolve(1)
}
return QIO.resolve({}).chain(() => a(n - 1))
}
defaultRuntime().unsafeExecutePromise(a(100000))
})
Apologies, I haven't confirmed this myself but it looks credible.
Would love to know if this is easily addressable since I'm getting ready to put QIO in place as the main evaluation context in a fairly large application, with one primary driver being stack safety.
From this discussion thread - https://functionalprogramming.slack.com/archives/C7BBY9A95/p1604439126428300?thread_ts=1603574914.302900&cid=C7BBY9A95
it appears the following code would blow the call stack