Created on 2008-12-07.00:00:00 last changed 161 months ago
Proposed resolution:
Add to [unique.ptr.dltr.dflt1]:
namespace std { template <class T> struct default_delete<T[]> { void operator()(T*) const; template <class U> void operator()(U*) const = delete; }; }
[ Batavia (2009-05): ]
We agree with the proposed resolution. Move to Tentatively Ready.
[ Post Summit: ]
Recommend Review.
Consider:
derived* p = new derived[3];
std::default_delete<base[]> d;
d(p); // should fail
Currently the marked line is a run time failure. We can make it a compile time failure by "poisoning" op(U*).
History | |||
---|---|---|---|
Date | User | Action | Args |
2011-08-23 20:07:26 | admin | set | status: wp -> c++11 |
2010-10-21 18:28:33 | admin | set | messages: + msg4460 |
2010-10-21 18:28:33 | admin | set | messages: + msg4459 |
2010-10-21 18:28:33 | admin | set | messages: + msg4458 |
2008-12-07 00:00:00 | admin | create |