Comment 15 for bug 1286611

Revision history for this message
Erik Ogenvik (erik-ogenvik) wrote :

Ok, I'm closing this issue since you're obviously not listening to a word I'm saying.

Yes, as I've said multiple times unique_ptr can help with _memory leaks_ caused by exceptions thrown in the constructor. No one is arguing against that.
However, as I've also stated you must also be able to correctly recover from an unexpected exception for there to be any benefit. If the process has to be shut down anyway there's not much gained.

What you're wrong about is however your assertion that it's unsafe to assign a pointer returned from a new statement, because you somehow think that the pointer returned could be invalid. This is simply not the case, and you've repeatedly now posted code which disproves you.