This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: Add ATTRIBUTE_PACKED to ansidecl.h
- From: "Kaveh R. GHAZI" <ghazi at caip dot rutgers dot edu>
- To: Nick Clifton <nickc at redhat dot com>
- Cc: gcc-patches at gcc dot gnu dot org, gdb-patches at sourceware dot org
- Date: Wed, 6 Dec 2006 18:40:30 -0500 (EST)
- Subject: Re: Add ATTRIBUTE_PACKED to ansidecl.h
- References: <m38xhk3nk9.fsf@redhat.com>
On Wed, 6 Dec 2006, Nick Clifton wrote:
> +/* Useful for structures whoes layout must much some binary specification
> + regardless of the alignment and padding qualities of the compiler. */
> +#ifndef ATTRIBUTE_PACKED
> +# define ATTRIBUTE_PACKED __attribute__ ((packed))
> +#endif
Please consider using "__packed__" not "packed". All the other ATTRIBUTE
macros use underscores to avoid conflicts with user-space macros.
Thanks,
--Kaveh
--
Kaveh R. Ghazi ghazi@caip.rutgers.edu