This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: problem with data alignment with egcs-19990602
- To: Mumit Khan <khan at xraylith dot wisc dot EDU>
- Subject: Re: problem with data alignment with egcs-19990602
- From: Jeffrey A Law <law at cygnus dot com>
- Date: Wed, 09 Jun 1999 03:14:22 -0600
- cc: Andris Pavenis <andris at stargate dot astr dot lu dot lv>, djgpp-workers at delorie dot com, egcs-patches at egcs dot cygnus dot com
- Reply-To: law at cygnus dot com
In message <199906082242.RAA19006@mercury.xraylith.wisc.edu>you write:
> Andris Pavenis <andris@stargate.astr.lu.lv> writes:
> > Problem seems to be related with use of #pragma pack():
> > I had to put definition of some structures between
> > #pragma pack(1)
> > and
> > #pragma pack()
> >
> > It looks that with gcc 2.95 tree the second line (#pragma pack())
> > is ignored and as result I'm getting wrong code.
[ ... ]
> The alignment should revert to the default when `#pragma pack()' is
> encountered (ie., without an token between the '(' and ')').
>
> Does the following fix it?
>
> Tue Jun 8 17:31:18 1999 Mumit Khan <khan@xraylith.wisc.edu>
>
> * c-pragma.c (handle_pragma_token): Handle `#pragma pack()'
> correctly.
I believe this is the right patch -- it is functionally identical to one
someone had just cobbled up inside Cygnus to fix the same problem.
I've installed your patch.
Thanks,
jeff