> On Feb 23, 2023, at 4:24 PM, Joseph Myers <jos...@codesourcery.com> wrote:
> 
> On Thu, 23 Feb 2023, Qing Zhao via Gcc-patches wrote:
> 
>> +@item
>> +The structure with a C99 flexible array member is the field of
>> +another union, for example:
>> +
>> +@smallexample
>> +struct flex1  @{ int length1; char data1[]; @}
>> +struct flex2  @{ int length2; char data2[]; @}
>> +
>> +union out_flex @{ struct flex1 flex_data1; struct flex2 flex_data2; @}
> 
> I don't think this is an extension; structures with flexible array members 
> are OK in unions in standard C.

Thanks for the info.

Just checked the small testing case with -Wpedantic, Yes, it’s accepted without 
any warning.
Will delete this item from the doc. And send the new patch soon.

Thanks.

Qing
> 
> -- 
> Joseph S. Myers
> jos...@codesourcery.com

Reply via email to