Detecting exception unwinding

Ola Fosheim Grøstad via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Wed Feb 3 03:09:00 PST 2016


Is there some reliable way to detect that a destructor is called 
because of exception unwinding?

I basically want to change behaviour within a destructor based on 
whether the destructor is called as a result of a regular or an 
exceptional situation.

E.g. commit changes to a database on regular destruction, or 
inhibit logging during exception unwinding.



More information about the Digitalmars-d-learn mailing list