Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The `run` function is actually quite optimized in Koka. At the point of the call to an effect function there is a O(1) lookup, due to this paper (https://www.microsoft.com/en-us/research/publication/general...).

After that depends on whether a continuation actually needs to be captured or not. Many useful effects can be implemented as `val` or `fun` clauses which can be called / accessed in place without any unwinding of the stack. Only in cases where a continuation is required is the continuation built up.



Thanks for the link! Koka (and Lean too) has produced quite some interesting papers.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: