sizeof wrong for struct with final zero-length array

Martin v. Loewis martin@loewis.home.cs.tu-berlin.de
Sun May 28 11:37:00 GMT 2000


> I order to support this feature, gcc needs to output debug symbol
> table entries that reflect the decl, rather than the type.  Debug
> information is beyond the scope of the C standard, and the STABS
> documentation at least doesn't address this case, so it would seem
> there is some freedom to implement the treatment of FAMs I describe.
> 
> Comments?

I think it would be definitely helpful to have such kind of
information in the debugger. However, it may be that you have to
create a new type in the debugging information for each variable, and
then have only one variable of the type.

Regards,
Martin



More information about the Gcc-bugs mailing list