Remove some inappropriate #includes.
Tom Lane <tgl@sss.pgh.pa.us>
Remove some inappropriate #includes. Other header files should never #include postgres.h (nor postgres_fe.h, nor c.h), per project policy. Also, there's no need for any backend .c file to explicitly include elog.h or palloc.h, because postgres.h pulls those in already. Extracted from a larger patch by Kyotaro Horiguchi. The rest of the removals he suggests require more study, but these are no-brainers. Discussion: https://postgr.es/m/20180215.200447.209320006.horiguchi.kyotaro@lab.ntt.co.jp
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/lib/knapsack.c | modified | +0 −1 |
| src/backend/replication/basebackup.c | modified | +0 −1 |
| src/backend/utils/misc/pg_config.c | modified | +0 −1 |
| src/backend/utils/misc/rls.c | modified | +0 −1 |
| src/include/lib/knapsack.h | modified | +0 −1 |
| src/pl/plpython/plpy_spi.h | modified | +0 −1 |
| src/pl/plpython/plpy_util.c | modified | +0 −1 |
Discussion
- Removing useless #include's. 4 messages · 2018-02-15 → 2018-02-16