public inbox for gcc-help@gcc.gnu.org
 help / color / mirror / Atom feed
From: Eljay Love-Jensen <eljay@adobe.com>
To: Mathieu Fluhr <mfluhr@nero.com>
Cc: gcc-help@gcc.gnu.org
Subject: Re: Anonymous union members problem
Date: Mon, 19 Apr 2004 14:28:00 -0000	[thread overview]
Message-ID: <6.0.3.0.2.20040419092054.01d08c00@iplan-mn.corp.adobe.com> (raw)
In-Reply-To: <1082382881.606.14.camel@c-l-175>

Hi Mathieu,

 >Humm... do you have any reference about that ?

Try "g++ -pedantic -Wall -W foo.cpp".

Anonymous structures and classes are not C++.  (Anonymous unions are C++.)

ISO 14882:1998 section 9.1

 >I already thought about these 2 possibilities... but none of them is 
actually suitable: this anonymous struct is generated by a macro that take 
a type as parameter (aim of the typedef) which is particular to this 
structure.  So any other idea ?

Then your code is not C++, it's merely C++-ish.

You'll need to use a compiler that is compatible with your source code's 
C++-ish variant.  There may be a GCC flag that relaxes the rules and would 
allow your code to compile with GCC 3.3.  I don't know of such a flag, off 
the top of my head.

HTH,
--Eljay

  reply	other threads:[~2004-04-19 14:28 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-04-19 13:09 Mathieu Fluhr
2004-04-19 13:15 ` Eljay Love-Jensen
2004-04-19 13:55   ` Mathieu Fluhr
2004-04-19 14:28     ` Eljay Love-Jensen [this message]
2004-04-19 14:59     ` llewelly
2004-04-19 14:53 ` llewelly

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6.0.3.0.2.20040419092054.01d08c00@iplan-mn.corp.adobe.com \
    --to=eljay@adobe.com \
    --cc=gcc-help@gcc.gnu.org \
    --cc=mfluhr@nero.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).