This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: gcc #pragma pack(push[,n]) target spesific ?
- From: James E Wilson <wilson at specifixinc dot com>
- To: mfletcher at serck-controls dot co dot uk
- Cc: gcc at gcc dot gnu dot org
- Date: Mon, 21 Feb 2005 19:25:38 -0800
- Subject: Re: gcc #pragma pack(push[,n]) target spesific ?
- References: <200502171640.16952.mfletcher@serck-controls.co.uk>
Matthew J Fletcher wrote:
Is this correct ?, comments in the appropreate config.h files indicate that
HANDLE_PRAGMA_PACK_PUSH_POP, is mostly used for wine compatablity, but is
there any reason why HANDLE_PRAGMA_PACK_PUSH_POP is not present on all
targets ? also there is not a configure option.
The pragma documentation states that we discouraged use of pragmas in
the past, because of language design problems fixed in the ISO C99
standard. Because of this, pragmas are only enabled for targets that
require them, for compatibility with other compilers.
As you mentioned yourself, HANDLE_PRAGMA_PACK_PUSH_POP is for win32
compatibility, and the *-elf targets don't require win32 compatibility,
generally. The only targets this is enabled for are ones that have
required use of it.
It might be reasonable to change the policy, and enable it for more
targets, or perhaps just for the embedded elf ones. It would also be
reasonable to improve the docs. I'd suggest filing a bug report into
bugzilla if you haven't already.
--
Jim Wilson, GNU Tools Support, http://www.SpecifixInc.com