News for hackers. Stuff that matters.
Re:Railway oriented programming by fpoling on Thursday June 23, 2016 @08:53AM (#11960492)
3) and 4) are essentially subclasses of 1) and to solve 1) one needs a typesystem like in Koka or PureScript where code is polymorphic regarding effects so introducing new one without breaking existing code is possible. PureScript uses that to precisely model JS exceptions.

As for 2) the exceptions are not zero-costs even with modern implementations and profile-driven optimizing compiler makes the runtime cost of wrapping/unwrapping low.

Re:Railway oriented programming by Rexxar on Thursday June 23, 2016 @09:54AM (#11960822)
C++ exception can be "zero cost" in the non exceptional path (for example http://llvm.org/docs/ExceptionHandling.html#itanium-abi-zero...)
Re:Railway oriented programming by fpoling on Thursday June 23, 2016 @10:29AM (#11961105)
Presence of exceptions still prevents some optimizations that the compiler can do otherwise like omitting frame pointer etc.