Updates destructors to use shorter C++ 11 loop and sets pointers to nullptr