Debian Codegraph @

clang-tools-extra/docs/clang-tidy/checks/bugprone/suspicious-include.rst

raw
1 .. title:: clang-tidy - bugprone-suspicious-include
2
3 bugprone-suspicious-include
4 ===========================
5
6 The check detects various cases when an include refers to what appears to be an
7 implementation file, which often leads to hard-to-track-down ODR violations.
8
9 Examples:
10
11 .. code-block:: c++
12
13 #include "Dinosaur.hpp" // OK, .hpp files tend not to have definitions.
14 #include "Pterodactyl.h" // OK, .h files tend not to have definitions.
15 #include "Velociraptor.cpp" // Warning, filename is suspicious.
16 #include_next <stdio.c> // Warning, filename is suspicious.