// File: main1.cpp // // Testing where the destructor gets called. #include #include "dmc.h" using namespace std ; int main() { cout << "\n\nEntering main()\n" ; DMC A ; { // a "local" scope cout << "\n\nEntering a local scope\n" ; DMC X ; cout << "Exiting a local scope\n" ; } { // another "local" scope cout << "\n\nEntering another local scope\n" ; DMC X[5] ; cout << "Exiting another local scope\n" ; } cout << "\n\nExiting main()\n" ; }