clang support the array initialization shorthand syntax [ first ... last ] = value <https://gcc.gnu.org/onlinedocs/gcc-10.2.0/gcc/Designated-Inits.html>, at least in clang >= 4.
2020-08-16 Bruno Haible <br...@clisp.org> regex: Use initializer shorthand syntax also with clang. * lib/regcomp.c (utf8_sb_map): Use the initializer shorthand syntax also with clang. diff --git a/lib/regcomp.c b/lib/regcomp.c index 93bb0a0..692928b 100644 --- a/lib/regcomp.c +++ b/lib/regcomp.c @@ -558,7 +558,7 @@ weak_alias (__regerror, regerror) static const bitset_t utf8_sb_map = { /* Set the first 128 bits. */ -# if defined __GNUC__ && !defined __STRICT_ANSI__ +# if (defined __GNUC__ || __clang_major__ >= 4) && !defined __STRICT_ANSI__ [0 ... 0x80 / BITSET_WORD_BITS - 1] = BITSET_WORD_MAX # else # if 4 * BITSET_WORD_BITS < ASCII_CHARS