c/8420: volatile after the type specifier for an unnamed structure is rejected

Richard Henderson rth@redhat.com
Wed Dec 11 15:46:00 GMT 2002


The following reply was made to PR c/8420; it has been noted by GNATS.

From: Richard Henderson <rth@redhat.com>
To: ehrhardt@mathematik.uni-ulm.de
Cc: gcc-gnats@gcc.gnu.org
Subject: Re: c/8420: volatile after the type specifier for an unnamed structure is rejected
Date: Wed, 11 Dec 2002 15:40:19 -0800

 On Fri, Nov 01, 2002 at 10:14:09AM -0000, ehrhardt@mathematik.uni-ulm.de wrote:
 > struct c {
 > 	struct  { int x; } volatile;
 > };  /* ERROR */
 > 
 > theseus$ gcc -Wall -c t.c
 > t.c:10: unnamed fields of type other than struct or union are not allowed
 [...]
 > Given the other two examples (struct a and struct b) which are accepted
 > this code should probably be legal.
 
 I don't agree.  I think this is very confusing syntax.
 
 > Even if it is illegal the error message is wrong.
 
 Granted.
 
 
 r~



More information about the Gcc-prs mailing list