by steveklabnik · 3y ago · 0 comments
I quite liked the (C#?) method where you have to strictly mark code as "unsafe" in order to use some features. I remember reading some code where in the comments there was a brief discussion about why it exists and alternatives explored.
Some of my old code even had to be robust against bit flipping (extremely safety critical). We had many code paths that could only be entered if bits were flipped in the execution triggering a reset, but also we had methods for ensuring the data memory was not tampered. I/O operations were purposefully difficult to initiate so that even if the entire execution memory was corrupted, there was an insanely low probability it would start I/O without triggering a reset.