rniwa wrote: > I don't understand this. For example, moving a `std::unique_ptr` does not > call `operator delete`. Nor does the destruction of the destructor of such a > moved-from object.
That is true. But once you've moved `std::unique_ptr`, you're not supposed to use/touch that object, or else you're doing use-after-move. For example, you're not supposed to access `x` after: ``` std::unique_ptr<Foo> x = make_unique<Foo>(); std::unique_ptr<Foo> y = std::move(x); ``` https://github.com/llvm/llvm-project/pull/184986 _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
