Jump to content    • Log In with Google      Sign In      •
Create Account     Epoch Error Handling, Part 2  Posted by
ApochPiQ, 16 September 2011 · 303 views  One excellent comment
on the previous entry on Epoch's error handling philosophy
observed that the design really looks an awful lot like
exceptions, and doesn't do much for the orthogonal separation of
the four points of error handling I enumerated at the top of
that post.  Let's revisit those points:    • Propagating error
information as failures occur   • Adjusting control flow in the
presence of error circumstances   • Maintaining certain
contractual semantics (this file will get closed, that memory
will get freed, etc.)   • Responding to and possibly recovering
from error conditions  In the last post, I introduced guard { }
entities and the evacuate() function. Together, these address
the first two points. evacuate() takes an optional parameter,
which is stored in a special out-of-band register in the VM, and
is recovered by the guard { } entity an