Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2004:
[Freeciv-Dev] Re: (PR#11282) [C++] typedef / struct member conflict in c
Home

[Freeciv-Dev] Re: (PR#11282) [C++] typedef / struct member conflict in c

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: fbriere@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#11282) [C++] typedef / struct member conflict in client/climisc.h
From: "Vasco Alexandre da Silva Costa" <vasc@xxxxxxxxxxxxxx>
Date: Wed, 1 Dec 2004 11:43:43 -0800
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=11282 >

On Wed, 1 Dec 2004, Jason Short wrote:

>
> <URL: http://rt.freeciv.org/Ticket/Display.html?id=11282 >
>
> Frédéric Brière wrote:
> > <URL: http://rt.freeciv.org/Ticket/Display.html?id=11282 >
> >
> > client/climisc.h has the following definition:
> >
> >   typedef int cid;
> >   ...
> >   struct item {
> >     cid cid;
> >     ...
> >
> >
> > I don't know if this is allowed or not in C++, but g++ chokes on this,
> > as it confuses both uses of cid.  This patch disambiguates this.
>
> Just change the 'cid' type to cid_type.  Or even better, figure out what
> 'cid' is supposed to mean and give it a legible name.

compound? complex?

---
Vasco Alexandre da Silva Costa @ Instituto Superior Tecnico, Lisboa








[Prev in Thread] Current Thread [Next in Thread]