Add declaration-level assertions for compile-time checks
Michael Paquier <michael@paquier.xyz>
Add declaration-level assertions for compile-time checks Those new assertions can be used at file scope, outside of any function for compilation checks. This commit provides implementations for C and C++, and fallback implementations. Author: Peter Smith Reviewed-by: Andres Freund, Kyotaro Horiguchi, Dagfinn Ilmari Mannsåker, Michael Paquier Discussion: https://postgr.es/m/201DD0641B056142AC8C6645EC1B5F62014B8E8030@SYD1217
Files
| Path | Change | +/− |
|---|---|---|
| src/backend/storage/page/bufpage.c | modified | +1 −8 |
| src/backend/utils/adt/lockfuncs.c | modified | +6 −0 |
| src/backend/utils/misc/guc.c | modified | +39 −0 |
| src/bin/pg_dump/pg_dump_sort.c | modified | +3 −0 |
| src/common/relpath.c | modified | +3 −0 |
| src/include/c.h | modified | +14 −4 |
| src/include/storage/bufpage.h | modified | +10 −0 |
Discussion
- Proposal: Add more compile-time asserts to expose inconsistencies. 41 messages · 2019-09-18 → 2020-03-10