7 ms·
No complaints about this in particular, but code that uses setjmp/longjmp often has a risk profile that's way bigger than memory safety alone. If you're stuck w
by gruntled-worker 3mo ago
No complaints about this in particular, but code that uses setjmp/longjmp often has a risk profile that's way bigger than memory safety alone. If you're stuck with them then by all means, mitigate all you can.
- pizlonator 3mo agoWhat misuse are you imagining that isn’t a memory safety problem? You might find that Fil-C prevents those too. It’s pretty strict. You can only use longjmp to pop stack like an exception would
- gruntled-worker 3mo agoResource leaks, crossing non-exception-safe library/system code, CPU-specific quirks like accidentally unrestored FP/vector/control state, etc. Granted it's always been highly system-specific stuff, but that's the worst kind.
- pizlonator 3mo agoGotcha, that’s a good list. It’s true that Fil-C doesn’t try to protect you from those bugs. I just don’t think of those as the worst things that can happen when you misuse these APIs.