In testing and debugging C++ code, there are often errors that visual studio can detect. Usually it responds by creating a breaking window pop up that let's you halt execution and inspect the call stack and values of variables etc.
I am wondering if there is any possible way to have the debugger throw an exception instead of doing it's normal break.
I want to be able to do something like:
try {
functionThatMightBreak(); // break as in, derefence null, uninitialized variable, iterator not derefenceable etc
} catch (SomeType e) {
// a bit more stuff
}