5 ms·
you can likely use SEH/Signals in zig to catch the panic and resume. In C++, you'll be lucky if you throw a nullptr exception. It's undefined behaviour, and it
by maccard 6y ago
you can likely use SEH/Signals in zig to catch the panic and resume.
In C++, you'll be lucky if you throw a nullptr exception. It's undefined behaviour, and it's often exploited by compilers for optimization. Here's a super simple example [0] showing how the compiler makes assumptions and generates a very unexpected result.
[0] https://gcc.godbolt.org/z/7159jGhex https://gcc.godbolt.org/z/7159jGhex