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

Commitb5c75fe

Browse files
committed
Remove to pre-8.2 coding convention for PG_MODULE_MAGIC
PG_MODULE_MAGIC has been around since 8.2, with 8.1 long since in EOL,so remove the mention of #ifdef guards for compiling against pre-8.2sources from the documentation.Author: Daniel Gustafsson <daniel@yesql.se>
1 parent04e9678 commitb5c75fe

File tree

5 files changed

+1
-20
lines changed

5 files changed

+1
-20
lines changed

‎contrib/citext/citext.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,9 +9,7 @@
99
#include"utils/formatting.h"
1010
#include"utils/varlena.h"
1111

12-
#ifdefPG_MODULE_MAGIC
1312
PG_MODULE_MAGIC;
14-
#endif
1513

1614
/*
1715
*====================

‎doc/src/sgml/plhandler.sgml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,7 @@
108108
#include "catalog/pg_proc.h"
109109
#include "catalog/pg_type.h"
110110

111-
#ifdef PG_MODULE_MAGIC
112111
PG_MODULE_MAGIC;
113-
#endif
114112

115113
PG_FUNCTION_INFO_V1(plsample_call_handler);
116114

‎doc/src/sgml/spi.sgml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4352,9 +4352,7 @@ INSERT INTO a SELECT * FROM a;
43524352
#include "executor/spi.h"
43534353
#include "utils/builtins.h"
43544354

4355-
#ifdef PG_MODULE_MAGIC
43564355
PG_MODULE_MAGIC;
4357-
#endif
43584356

43594357
int64 execq(text *sql, int cnt);
43604358

‎doc/src/sgml/xfunc.sgml

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1757,20 +1757,13 @@ CREATE FUNCTION square_root(double precision) RETURNS double precision
17571757
file contains a <quote>magic block</> with the appropriate contents.
17581758
This allows the server to detect obvious incompatibilities, such as code
17591759
compiled for a different major version of
1760-
<productname>PostgreSQL</productname>. A magic block is required as of
1761-
<productname>PostgreSQL</productname> 8.2. To include a magic block,
1760+
<productname>PostgreSQL</productname>. To include a magic block,
17621761
write this in one (and only one) of the module source files, after having
17631762
included the header <filename>fmgr.h</>:
17641763

17651764
<programlisting>
1766-
#ifdef PG_MODULE_MAGIC
17671765
PG_MODULE_MAGIC;
1768-
#endif
17691766
</programlisting>
1770-
1771-
The <literal>#ifdef</> test can be omitted if the code doesn't
1772-
need to compile against pre-8.2 <productname>PostgreSQL</productname>
1773-
releases.
17741767
</para>
17751768

17761769
<para>
@@ -2214,9 +2207,7 @@ PG_FUNCTION_INFO_V1(funcname);
22142207
#include "fmgr.h"
22152208
#include "utils/geo_decls.h"
22162209

2217-
#ifdef PG_MODULE_MAGIC
22182210
PG_MODULE_MAGIC;
2219-
#endif
22202211

22212212
/* by value */
22222213

@@ -2554,9 +2545,7 @@ SELECT name, c_overpaid(emp, 1500) AS overpaid
25542545
#include "postgres.h"
25552546
#include "executor/executor.h" /* for GetAttributeByName() */
25562547

2557-
#ifdef PG_MODULE_MAGIC
25582548
PG_MODULE_MAGIC;
2559-
#endif
25602549

25612550
PG_FUNCTION_INFO_V1(c_overpaid);
25622551

‎src/test/regress/regress.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,7 @@
4646
externPATH*poly2path(POLYGON*poly);
4747
externvoidregress_lseg_construct(LSEG*lseg,Point*pt1,Point*pt2);
4848

49-
#ifdefPG_MODULE_MAGIC
5049
PG_MODULE_MAGIC;
51-
#endif
5250

5351

5452
/*

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp