So far I can't find how to deduce that the following:
int* ptr; *ptr = 0;
is undefined behavior.
First of all, there's 5.3.1/1 that states that
* means indirection which converts
T. But this doesn't say anything about UB.
Then there's often quoted 184.108.40.206/4 saying that using deallocation function on a non-null pointer renders the pointer invalid and later usage of the invalid pointer is UB. But in the code above there's nothing about deallocation.
How can UB be deduced in the code above?