pure virtual desturctor in C++

It is possible to have a pure virtual destructor. Pure virtual destructors are legal in standard C++ and one of the most important things to remember is that if a class contains a pure virtual destructor, it must provide a function body for the pure virtual destructor. 
Why a pure virtual function requires a function body?
The reason is that destructors (unlike other functions) are not actually ‘overridden’, rather they are always called in the reverse order of the class derivation. This means that a derived class destructor will be invoked first, then the base class destructor will be called. If the definition of the pure virtual destructor is not provided, then what function body will be called during object destruction? Therefore the compiler and linker enforce the existence of a function body for pure virtual destructors. 
```
#include <iostream>
using namespace std;
 
class Base {
public:
    virtual ~Base() = 0;
};
Base::~Base() // Explicit destructor call
{
    std::cout << "Pure virtual destructor is called\n";
}

class Derived : public Base {
public:
    ~Derived() { cout << "~Derived() is executed\n"; }
};
 
int main()
{
    Base* b = new Derived();
    delete b;
    return 0;
}
```