diff options
author | Bruce Momjian | 2003-03-18 17:21:07 +0000 |
---|---|---|
committer | Bruce Momjian | 2003-03-18 17:21:07 +0000 |
commit | 6cf8ce13dbbc8f0a6e2ee46907a46dd0613ae319 (patch) | |
tree | bbe7fb98bb27c80fcb1e6ef912dd8593138b9072 /src/include/postgres_ext.h | |
parent | 526de7ffd16a7d308ec96bb23fb5cf38f85f3dd2 (diff) |
Compiling anything that uses InvalidOid under g++ yields a warning about
the expression using an "old-style cast." Therefore, would it be okay
to patch postgres_ext.h as follows:
Jeroen T. Vermeulen
Diffstat (limited to 'src/include/postgres_ext.h')
-rw-r--r-- | src/include/postgres_ext.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/include/postgres_ext.h b/src/include/postgres_ext.h index d4e5b4ebbfa..b252453bbff 100644 --- a/src/include/postgres_ext.h +++ b/src/include/postgres_ext.h @@ -15,7 +15,7 @@ * use header files that are otherwise internal to Postgres to interface * with the backend. * - * $Id: postgres_ext.h,v 1.11 2002/08/13 20:40:44 momjian Exp $ + * $Id: postgres_ext.h,v 1.12 2003/03/18 17:21:07 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -28,7 +28,11 @@ */ typedef unsigned int Oid; +#ifdef __cplusplus +#define InvalidOid (Oid(0)) +#else #define InvalidOid ((Oid) 0) +#endif #define OID_MAX UINT_MAX /* you will need to include <limits.h> to use the above #define */ |