conflicting types for `struct Oid' - Mailing list pgsql-hackers

From Corrado Giacomini
Subject conflicting types for `struct Oid'
Date
Msg-id 3A5DEAF5.35931339@acresearch.com
Whole thread Raw
List pgsql-hackers
Dear All,
I currently developing a project using SNMP++ and posgresql (7.0.3)
libpq++
Since both SNMP and posgresql  define  an Oid type

typedef unsigned int Oid  (postgresql)
struct Oid (SNMP++)

At compilation time I get this error :

/deliveries/external/SNMP++/3.4Patched/snmp++/include/oid.h:94:
conflicting types for `struct Oid'
/deliveries/external/postgres/7.0.3/include/postgres_ext.h:28: previous
declaration as `typedef unsigned int Oid'

I tryed to encampsulate my postgres derived classes into a namespace but
then I got a lot of other compilation errors
where in my code I am using STL classes.

Is there e simple solution to my problem ? is there a way to use
namespace in order  to avoid conflicting types ?

Thanks in advance to everybody,
   -Corrado





pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: MS Access vs IS NULL (was Re: [BUGS] Bug in SQL functions that use a NULL parameter directly)
Next
From: "Steve Howe"
Date:
Subject: Must implement PQnotifyFree()