diff options
author | Peter Eisentraut <peter@eisentraut.org> | 2025-01-15 18:57:53 +0100 |
---|---|---|
committer | Peter Eisentraut <peter@eisentraut.org> | 2025-01-15 18:57:53 +0100 |
commit | 74938d132093bc0ad99a5420da2e99edaa3734f9 (patch) | |
tree | 91730468d8ce4968b2a6bfefed99ea17f82405fc /src/interfaces/libpq/libpq-int.h | |
parent | 761c79508e7fbc33c1b11754bdde4bd03ce9cbb3 (diff) | |
download | postgresql-74938d132093bc0ad99a5420da2e99edaa3734f9.tar.gz postgresql-74938d132093bc0ad99a5420da2e99edaa3734f9.zip |
IWYU widely useful pragmas
Add various widely useful "IWYU pragma" annotations, such as
- Common header files such as c.h, postgres.h should be "always_keep".
- System headers included in c.h, postgres.h etc. should be considered
"export".
- Some portability headers such as getopt_long.h should be
"always_keep", so they are not considered superfluous on some
platforms.
- Certain system headers included from portability headers should be
considered "export" because the purpose of the portability header is
to wrap them.
- Superfluous includes marked as "for backward compatibility" get a
formal IWYU annotation.
- Generated header included in utils/syscache.h is marked exported.
This is a very commonly used include and this avoids lots of
complaints.
Discussion: https://www.postgresql.org/message-id/flat/9395d484-eff4-47c2-b276-8e228526c8ae@eisentraut.org
Diffstat (limited to 'src/interfaces/libpq/libpq-int.h')
-rw-r--r-- | src/interfaces/libpq/libpq-int.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/interfaces/libpq/libpq-int.h b/src/interfaces/libpq/libpq-int.h index 031b93c535b..4be5fd7ae4f 100644 --- a/src/interfaces/libpq/libpq-int.h +++ b/src/interfaces/libpq/libpq-int.h @@ -44,6 +44,7 @@ #include "fe-auth-sasl.h" #include "pqexpbuffer.h" +/* IWYU pragma: begin_exports */ #ifdef ENABLE_GSS #if defined(HAVE_GSSAPI_H) #include <gssapi.h> @@ -51,6 +52,7 @@ #include <gssapi/gssapi.h> #endif #endif +/* IWYU pragma: end_exports */ #ifdef ENABLE_SSPI #define SECURITY_WIN32 |