Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit87ca3bd

Browse files
committed
#undef const, inline, signed, volatile, on the expectation that a C++
compiler will understand them. configure may have #define'd them toempty because the local C compiler doesn't understand them, but thismay very well cause a C++ compilation to fail, so don't do it in C++.
1 parent07672d4 commit87ca3bd

File tree

2 files changed

+18
-2
lines changed

2 files changed

+18
-2
lines changed

‎src/interfaces/libpq++/libpq++.h

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
1414
* Portions Copyright (c) 1994, Regents of the University of California
1515
*
16-
* $Id: libpq++.h,v 1.7 2000/03/30 05:30:42 tgl Exp $
16+
* $Id: libpq++.h,v 1.8 2000/04/14 01:00:16 tgl Exp $
1717
*
1818
*-------------------------------------------------------------------------
1919
*/
@@ -25,6 +25,14 @@ extern "C" {
2525
#include"config.h"
2626
}
2727

28+
/* We assume that the C++ compiler will have these keywords, even though
29+
* config.h may have #define'd them to empty because C compiler doesn't.
30+
*/
31+
#undef const
32+
#undef inline
33+
#undef signed
34+
#undef volatile
35+
2836
#ifdef HAVE_CXX_STRING_HEADER
2937
#include<string>
3038
#endif

‎src/interfaces/libpq++/pgconnection.h

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* Portions Copyright (c) 1996-2000, PostgreSQL, Inc
1414
* Portions Copyright (c) 1994, Regents of the University of California
1515
*
16-
* $Id: pgconnection.h,v 1.5 2000/03/30 05:30:42 tgl Exp $
16+
* $Id: pgconnection.h,v 1.6 2000/04/14 01:00:16 tgl Exp $
1717
*
1818
*-------------------------------------------------------------------------
1919
*/
@@ -25,6 +25,14 @@ extern "C" {
2525
#include"config.h"
2626
}
2727

28+
/* We assume that the C++ compiler will have these keywords, even though
29+
* config.h may have #define'd them to empty because C compiler doesn't.
30+
*/
31+
#undef const
32+
#undef inline
33+
#undef signed
34+
#undef volatile
35+
2836
#ifdef HAVE_CXX_STRING_HEADER
2937
#include<string>
3038
#endif

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp