Re: [RFC][PATCH v1 1/4] Documentation change

2024-04-23 Thread Qing Zhao
> On Apr 23, 2024, at 15:03, Joseph Myers wrote: > > On Tue, 23 Apr 2024, Qing Zhao wrote: > >> However, I am not very confident on the wording of the doc, is the >> current wording good enough for this? Or do you have any suggestion on >> how to make it better? > > I'm not convinced the

Re: [RFC][PATCH v1 1/4] Documentation change

2024-04-23 Thread Joseph Myers
On Tue, 23 Apr 2024, Qing Zhao wrote: > However, I am not very confident on the wording of the doc, is the > current wording good enough for this? Or do you have any suggestion on > how to make it better? I'm not convinced the statement about size (in relation to a structure with the member

Re: [RFC][PATCH v1 1/4] Documentation change

2024-04-23 Thread Qing Zhao
> On Apr 23, 2024, at 14:04, Joseph Myers wrote: > > On Fri, 19 Apr 2024, Qing Zhao wrote: > >> +The size of the union is as if the flexiable array member were omitted >> +except that it may have more trailing padding than the omission would imply. > > "trailing padding" is more a concept

Re: [RFC][PATCH v1 1/4] Documentation change

2024-04-23 Thread Joseph Myers
On Fri, 19 Apr 2024, Qing Zhao wrote: > +The size of the union is as if the flexiable array member were omitted > +except that it may have more trailing padding than the omission would imply. "trailing padding" is more a concept for structures than for unions (where padding depends on which

Re: [RFC][PATCH v1 1/4] Documentation change

2024-04-22 Thread Qing Zhao
> On Apr 19, 2024, at 16:54, Tom Tromey wrote: > >> Qing Zhao writes: > >> +The size of the union is as if the flexiable array member were omitted >> +except that it may have more trailing padding than the omission would imply. >> + >> +If all the members of a union are flexiable array

Re: [RFC][PATCH v1 1/4] Documentation change

2024-04-19 Thread Tom Tromey
> Qing Zhao writes: > +The size of the union is as if the flexiable array member were omitted > +except that it may have more trailing padding than the omission would imply. > + > +If all the members of a union are flexiable array member, the size of There's a couple of spots that say

[RFC][PATCH v1 1/4] Documentation change

2024-04-19 Thread Qing Zhao
for allow flexible array members in unions and alone in structures [PR53548] The request for GCC to accept that the C99 flexible array member can be in a union or alone in a structure has been made a long time ago around 2012 for supporting several practical cases including glibc. A GCC PR has