You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
N3797 20.8.1.2.5 [unique.ptr.single.modifiers]/4 says: "assigns p to the stored pointer, and then if the old value of the stored pointer, old_p, was not equal to nullptr, calls get_deleter()(old_p)."
It should say "if and only if" in order to be absolutely clear that the deleter won't be called with a null pointer.
(I believe that the intention was obvious, so this is editorial. Note that 20.8.1.2.2 [unique.ptr.single.dtor]/2's phrasing is unambiguous: "If get() == nullptr there are no effects. Otherwise get_deleter()(get()).")
The text was updated successfully, but these errors were encountered:
N3797 20.8.1.2.5 [unique.ptr.single.modifiers]/4 says: "assigns p to the stored pointer, and then if the old value of the stored pointer, old_p, was not equal to nullptr, calls get_deleter()(old_p)."
It should say "if and only if" in order to be absolutely clear that the deleter won't be called with a null pointer.
(I believe that the intention was obvious, so this is editorial. Note that 20.8.1.2.2 [unique.ptr.single.dtor]/2's phrasing is unambiguous: "If get() == nullptr there are no effects. Otherwise get_deleter()(get()).")
The text was updated successfully, but these errors were encountered: