//dphase.h:
class DestructionPhase {
int m_phase; // the smaller the phase, the later the object
// should be destroyed
public:
explicit DestructionPhase (int phase) : m_phase(phase) {}
bool operator> (const DestructionPhase& dp) const
{ return m_phase > dp.m_phase; }
};