From: uz Date: Sun, 30 Aug 2009 08:30:55 +0000 (+0000) Subject: Any field without a name is legal but useless in a union. X-Git-Tag: V2.13.0rc1~170 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=2ddeb069eb54466172c38e315d50ce029b4febc3;p=cc65 Any field without a name is legal but useless in a union. git-svn-id: svn://svn.cc65.org/cc65/trunk@4086 b7a2c559-68d2-44c3-8de9-860c34a00d81 --- diff --git a/src/cc65/declare.c b/src/cc65/declare.c index 9a9229689..6c722be2f 100644 --- a/src/cc65/declare.c +++ b/src/cc65/declare.c @@ -556,14 +556,9 @@ static SymEntry* ParseUnionDecl (const char* Name) /* Check for fields without a name */ if (Decl.Ident[0] == '\0') { - if (FieldWidth < 0) { - /* A non bit-field without a name is legal but useless */ - Warning ("Declaration does not declare anything"); - goto NextMember; - } else { - /* A bit-field without a name does nothing in a union */ - goto NextMember; - } + /* Any field without a name is legal but useless in a union */ + Warning ("Declaration does not declare anything"); + goto NextMember; } /* Handle sizes */