#include <iostream> struct A{ ~A() { std::cout << "destructor\n"; }}; int main() { A* a = new A[10]; delete a;}
Standard input is empty
destructor
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!