Hi, I have an auto-duration only class X in C++0x:
class X {
void* operator new(std::size_t) = delete;
void operator delete(void*) = delete;
public:
virtual ~X() {}
};
But GCC 4.4 fails to compile it:
main.cpp: In destructor 'virtual X::~X()':
main.cpp:4140: error: deleted function 'static void X::operator delete(void*)'
main.cpp:4144: error: used here
Is it a bug? If not, then why is it needed?
I have a similar example with a missing "unneeded" copy constructor.
Best regards, Piotr
