https://gcc.gnu.org/bugzilla/show_bug.cgi?id=117178
--- Comment #4 from Alejandro Colomar <alx at kernel dot org> ---
+1
The proposal makes sense to me. I had originally proposed something such as
char x[3] = "foo"u;
for marking that as a non-string. But that was because I didn't know about
[[gnu::nonstring]]. The attribute makes more sense.
As for C++, maybe such an initialization should be acceptable as a GNU
extension. However, I don't care anymore what happens to C++, so whatever.
:-)
In C, this should certainly be silenceable with the attribute.