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

Commitb46d9be

Browse files
committed
With ancient gcc, skip pg_attribute_printf() on function pointer.
Buildfarm results show that the ability to attach pg_attribute_printfdecoration to a function pointer appeared somewhere between gcc 2.95.3and gcc 4.0.1. Guess that it was there in 4.0.
1 parent9a83564 commitb46d9be

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

‎src/bin/psql/psqlscan.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,12 @@ typedef struct PsqlScanCallbacks
3232
/* This pointer can be NULL if no variable substitution is wanted */
3333
char*(*get_variable) (constchar*varname,boolescape,boolas_ident);
3434
/* Print an error message someplace appropriate */
35+
/* (very old gcc versions don't support attributes on function pointers) */
36+
#if defined(__GNUC__)&&__GNUC__<4
37+
void(*write_error) (constchar*fmt,...);
38+
#else
3539
void(*write_error) (constchar*fmt,...)pg_attribute_printf(1,2);
40+
#endif
3641
}PsqlScanCallbacks;
3742

3843

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp