This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Zero-length arrays


Linus Torvalds writes ...
> 
> In article <718D38CAB6E0D011B2C90060970C28A5642562@EXCHANGESERVER> you write:
> >
> >>  Aren't they only allowed at the *end* of structs ?
> >>
> >>That's what the documentation implies (though it's less clear that it
> >>could be) but there's no code to check for it.
> >>
> >>Note that zero-length arrays should be allowed anywhere, but everywhere but
> >>the end they really *are* zero length and aren't extendable.
> >
> >  I can't see the point in a genuine 0-length array ?
> 
> Actually, they do occur quite naturally in certain circumstances.

If you had followed the entire thread, you would have noticed that
"genuine" in this context means "0-length arrays other than the kind
you posted about".

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]