News for hackers. Stuff that matters.
Re:Janet – A dynamic language and bytecode VM by bakpakin on Sunday February 17, 2019 @05:31PM (#19187312)
Janet uses setjmp/longjmp for error handling because most alternatives in C don't compose well or are incredibly verbose/inefficient. The C API is not documented yet, but in general one could use setjmp at C++/Rust <-> C boundary points to prevent panics from jumping over C++/Rust stack frames. However, many functions in the C API will not panic (longjmp to the last save point). The overhead could be minimized by only calling setjmp for API calls that can panic.

Just spitballing here.

There are no comments on this comment yet.