[v3] annex D 8 and 9 for C++0x
Fri Oct 26 21:33:00 GMT 2007
>> Do we really need to warn about auto_ptr<>?
> Is it in Annex D in C++0x? If so, then yes. Why would it be treated
> differently than anything else?
One alternative that hasn't been mentioned is to "fix" it instead of
deprecating it wholesale:
template<class T> class auto_ptr
auto_ptr( auto_ptr && r );
auto_ptr( auto_ptr & r ) __attribute__( deprecated );
The idea is to keep code that uses it as if it were an unique_ptr
warning-free. I don't know how practical this would be, though.
More information about the Libstdc++