4 ms·
> I never quite understood why unique_ptr and move semantics are supposed to improve memory safety over new and delete. [...] Though it isn't the type of safet
by lomnakkus 10y ago
> I never quite understood why unique_ptr and move semantics are supposed to improve memory safety over new and delete. [...]
Though it isn't the type of safety you're thinking of, if you use make_unique/make_shared you'll also be exception-safe... which is a very nice benefit.