Hacker News new | comments | show | ask | jobs | submit login

I really like this idea. I took a look at the Javascript output of the compiler, and noticed that effectively every statement of the program would result in a function nested within the function created by the last N statements. Since Javascript doesn't have tail call optimization, the browser will complain at some point when the stack overflows.

Contrived, I know, but it looks like in Firefox 8 that happens at around 39k.




This is an important issue! I'm aware of the problem and have some ideas of how to avoid it. My compiler is not actually doing any optimization at this stage, so this will be addressed when I give this more attention.


Keep in mind that some implementations, notably V8, do do tail call optimization; and I'm sure IonMonkey or one of its successors eventually will.




Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | DMCA | Apply to YC | Contact

Search: