This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug pending/31709] New: combine and __attributes__((__packed__)) conflict.
- From: "matt at 3am-software dot com" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 26 Apr 2007 01:45:51 -0000
- Subject: [Bug pending/31709] New: combine and __attributes__((__packed__)) conflict.
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
a.c:
struct f { int i; } __attribute__((__packed__));
const char *foo(struct f *);
b.c:
struct f;
const char *foo(struct f *);
c.c (identical to a.c):
struct f { int i; } __attribute__((__packed__));
const char *foo(struct f *);
gcc -fsyntax-only -combine -ffreestanding a.c b.c c.c
c.c:3: error: conflicting types for 'foo'
b.c:3: error: previous declaration of 'foo' was here
There is no difference even if b.c includes attribute((__packed__)). Changing
the order such that b.c is either first or last suppresses the error.
--
Summary: combine and __attributes__((__packed__)) conflict.
Product: gcc
Version: 4.1.2
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: pending
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: matt at 3am-software dot com
GCC build triplet: x86_64--netbsd
GCC host triplet: x86_64--netbsd
GCC target triplet: x86_64--netbsd
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=31709