https://gcc.gnu.org/bugzilla/show_bug.cgi?id=116284

--- Comment #3 from Alejandro Colomar <alx at kernel dot org> ---
I have intentions to propose 0-length arrays as a standard language feature, or
at least a well-supported GCC extension.

Proposals such as <https://www.open-std.org/jtc1/sc22/wg14/www/docs/n3188.htm>
will make evident that 0-length arrays are necessary in the language, such as
in memcpy(3)ing 0 bytes.  Consider a hypothetical prototype of wmemcpy(3):

    wchar_t *wmemcpy(wchar_t dst[.n], wchar_t src[.n], size_t n);

That will require at least partial support of 0-length arrays.

I understand that current support is partial, but I'd like that to get fixed,
at least if there's no deep problems triggered by adding support for it.

Reply via email to