Cesium
Cesium copied to clipboard
IO exception handling in stdlib
Certain stdlib functions are documented to return various error codes. For example, putc
should return EOF
in case an error occurs.
But how could it signal the exact exception kind, and exception information?
Ideally, I'd like to store it somewhere together with the last error code, and expose for the user program if possible.
We should check what the standard says on error codes and how errors generally behave, and invent a similarly-behaving extension that exposes the structured exception information.
See // TODO[#154]
in the code when implementing this.