Most people used std::uncaught_exception() to try to determine if debugging is waiting, so they can throw an exception from the destructor if it is not already there. This is usually considered not a good idea.
If you want to not cancel the operation, if an exception occurs, it should do the trick.
Remember that the destructor is your last chance to free any resources that the object has, because after the destructor completes, the object does not exist, and all remaining resources are now constantly leaking. If OpDo() allocates any memory files or files or something else, you need to deal with this in the destructor, no matter what.
David thornley
source share