On Wed, 24 May 2023 at 10:42, Florian Weimer wrote: > Well, one might be tempted to write that explicit memset to eliminate > the conditional branch, except that it's technically required because > data() might return nullptr. 8-/
Which is why you shouldn't write that code :-) But this is a digression from the original point, which is that nonnull attributes are used in glibc and libstdc++, which are widely used. So improvements to diagnostics for the attribute would not be a waste of time.