In article <f4028321-ff6f-27a8-011d-b79e3bba4...@gmx.com>, Kamil Rytarowski <n...@gmx.com> wrote: >-=-=-=-=-=- >-=-=-=-=-=- > >On 24.02.2020 13:41, Joerg Sonnenberger wrote: >> On Mon, Feb 24, 2020 at 11:42:01AM +0100, Kamil Rytarowski wrote: >>> Forbidding NULL pointer arithmetic is not just for C purists trolls. It >>> is now in C++ mainstream and already in C2x draft. >> >> This is not true. NULL pointer arithmetic and nullptr arithmetic are >> *very* different things. Do not conflate them. >> >> Joerg >> > >As noted, they are allowed to be practically the same in C++. The C >proposal (n2394) NULL is marked as deprecated and NULL should be set to >nullptr.
This is just a proposal; once it becomes part of the standard we can worry about it. I agree with the rest of the people that we should (for now) change these cases in the sanitizer to not produce errors instead of making the code more complicated, to make the sanitizer happy. christos