diff --git a/.github/workflows/iwyu.yml b/.github/workflows/iwyu.yml index 667c0ee3f..d27022ce6 100644 --- a/.github/workflows/iwyu.yml +++ b/.github/workflows/iwyu.yml @@ -28,7 +28,7 @@ jobs: - name: Prepare CMake run: | - cmake -S . -B cmake.output -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release -DHAVE_RULES=On -DBUILD_TESTS=On -DBUILD_GUI=On -DBUILD_TESTS=On -DBUILD_GUI=On -DWITH_QCHART=On -DCMAKE_GLOBAL_AUTOGEN_TARGET=On -DCMAKE_DISABLE_PRECOMPILE_HEADERS=On -DCPPCHK_GLIBCXX_DEBUG=Off -DUSE_MATCHCOMPILER=Off + cmake -S . -B cmake.output -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=Release -DHAVE_RULES=On -DBUILD_TESTS=On -DBUILD_GUI=On -DBUILD_TESTS=On -DBUILD_GUI=On -DWITH_QCHART=On -DENABLE_CHECK_INTERNAL=On -DCMAKE_GLOBAL_AUTOGEN_TARGET=On -DCMAKE_DISABLE_PRECOMPILE_HEADERS=On -DCPPCHK_GLIBCXX_DEBUG=Off -DUSE_MATCHCOMPILER=Off - name: Prepare CMake dependencies run: | diff --git a/lib/checkinternal.h b/lib/checkinternal.h index 939e7327b..5cd875e42 100644 --- a/lib/checkinternal.h +++ b/lib/checkinternal.h @@ -24,10 +24,15 @@ #include "check.h" #include "config.h" +#include "errortypes.h" #include "settings.h" #include +class ErrorLogger; +class Token; +class Tokenizer; + /// @addtogroup Checks /// @{ diff --git a/lib/cppcheck.h b/lib/cppcheck.h index 560823203..5889b63dd 100644 --- a/lib/cppcheck.h +++ b/lib/cppcheck.h @@ -32,7 +32,7 @@ #include #include // IWYU pragma: keep #include -#include +#include #include #include #include diff --git a/lib/smallvector.h b/lib/smallvector.h index 738e53dae..0079554f7 100644 --- a/lib/smallvector.h +++ b/lib/smallvector.h @@ -29,6 +29,7 @@ static constexpr std::size_t DefaultSmallVectorSize = 0; template using SmallVector = boost::container::small_vector; #else +#include #include template diff --git a/lib/tokenrange.h b/lib/tokenrange.h index b1405821d..0498ceecf 100644 --- a/lib/tokenrange.h +++ b/lib/tokenrange.h @@ -23,6 +23,12 @@ #include "config.h" +#include +#include +#include + +class Token; + template )> class TokenRangeBase { T* mFront; diff --git a/lib/valueflow.h b/lib/valueflow.h index cddbbf8ea..e05077498 100644 --- a/lib/valueflow.h +++ b/lib/valueflow.h @@ -24,7 +24,6 @@ #include "config.h" #include "mathlib.h" -#include #include #include #include diff --git a/lib/valueptr.h b/lib/valueptr.h index 45ca7d94e..7d65f976d 100644 --- a/lib/valueptr.h +++ b/lib/valueptr.h @@ -22,7 +22,6 @@ //--------------------------------------------------------------------------- #include "config.h" -#include #include template