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]
Other format: [Raw text]

Re: PARM_DECL of DECL_SIZE 0, but TYPE_SIZE of 96 bits


On Wed, Jun 29, 2005 at 06:57:12PM -0400, Daniel Berlin wrote:
> I'm going to work around this by using TYPE_SIZE, but it would be nice
> if somebody could explain the purpose for this behavior (if it's a bug,
> i'll file a bug report). I would imagine we don't have truly empty
> things in C++, so you could simply assert that TREE_INT_CST_LOW of
> whatever you are setting DECL_SIZE to is not 0 and find these that way.

It is most definitely a bug.  I'm surprised about the 0 instead
of a NULL there.  The later would easily be explicable by 
forgetting to call layout_decl.

My only guess is that this decl had an incomplete type at some
point.  Is the function in question a template?  I could see as
how maybe we need to call relayout_decl after instantiation, or
simply re-order how the parm_decls are created.


r~


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