From fa00b8c02c9de6dca833b83dc6447ba31d72ca57 Mon Sep 17 00:00:00 2001 From: MarcoFalke <*~=`'#}+{/-|&$^_@721217.xyz> Date: Tue, 20 May 2025 18:20:32 +0200 Subject: [PATCH] doc: Remove section about include guards --- doc/developer-notes.md | 10 ---------- test/lint/lint-include-guards.py | 2 +- 2 files changed, 1 insertion(+), 11 deletions(-) diff --git a/doc/developer-notes.md b/doc/developer-notes.md index b9965b4f4d3..ed2fa64b591 100644 --- a/doc/developer-notes.md +++ b/doc/developer-notes.md @@ -1160,16 +1160,6 @@ namespace { - *Rationale*: Avoids confusion about the namespace context. -- Use include guards to avoid the problem of double inclusion. The header file - `foo/bar.h` should use the include guard identifier `BITCOIN_FOO_BAR_H`, e.g. - -```c++ -#ifndef BITCOIN_FOO_BAR_H -#define BITCOIN_FOO_BAR_H -... -#endif // BITCOIN_FOO_BAR_H -``` - GUI ----- diff --git a/test/lint/lint-include-guards.py b/test/lint/lint-include-guards.py index 77af05c1c2e..e16bb94a770 100755 --- a/test/lint/lint-include-guards.py +++ b/test/lint/lint-include-guards.py @@ -83,7 +83,7 @@ def main(): if count != 3: print(f'{header_file} seems to be missing the expected ' - 'include guard:') + 'include guard to prevent the double inclusion problem:') print(f' #ifndef {header_id}') print(f' #define {header_id}') print(' ...')