On 02/11/17 19:25, Vicente J. Botet Escriba via Boost wrote:
Hi,
boost::aligned_storage is not a POD.
I suspect it is because of the declared constructors
private: // noncopyable
aligned_storage(const aligned_storage&); aligned_storage& operator=(const aligned_storage&);
public: // structors
aligned_storage() { }
~aligned_storage() { }
Was this intentional?
Why aligned_storage is not copyable?
The usage pattern of boost::aligned_storage is different from that of std::aligned_storage. You can get a POD type through the nested type typedef: typedef boost::aligned_storage< 16 >::type aligned_storage_pod; I think, boost::aligned_storage is not copyable because it doesn't know how to copy the contents. And since in C++03 it can't define =default constructors, it had to define a user-defined constructor making the type non-POD.