summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2023-05-15 20:50:13 (GMT)
committerBen Boeckel <ben.boeckel@kitware.com>2023-05-16 02:26:36 (GMT)
commite8efcbec8c7e66e6e7ab45354189b9fc4166938e (patch)
tree6b2684757f31ec610ba0a7d3e2bd574919135dc7
parent2b086065114049a7b5e18ead441b5b8ae6fc7ba0 (diff)
downloadCMake-e8efcbec8c7e66e6e7ab45354189b9fc4166938e.zip
CMake-e8efcbec8c7e66e6e7ab45354189b9fc4166938e.tar.gz
CMake-e8efcbec8c7e66e6e7ab45354189b9fc4166938e.tar.bz2
iwyu: ignore `std::remove_reference` requirements
This removes some includes from some existing files.
-rw-r--r--Source/cmCMakeHostSystemInformationCommand.cxx1
-rw-r--r--Source/cmString.cxx1
-rw-r--r--Tests/CMakeLib/testStringAlgorithms.cxx3
-rw-r--r--Utilities/IWYU/mapping.imp1
4 files changed, 2 insertions, 4 deletions
diff --git a/Source/cmCMakeHostSystemInformationCommand.cxx b/Source/cmCMakeHostSystemInformationCommand.cxx
index 8bfd7c8..1c00f15 100644
--- a/Source/cmCMakeHostSystemInformationCommand.cxx
+++ b/Source/cmCMakeHostSystemInformationCommand.cxx
@@ -8,7 +8,6 @@
#include <initializer_list>
#include <map>
#include <string>
-#include <type_traits>
#include <utility>
#include <cm/optional>
diff --git a/Source/cmString.cxx b/Source/cmString.cxx
index aefaa64..f7f6293 100644
--- a/Source/cmString.cxx
+++ b/Source/cmString.cxx
@@ -9,7 +9,6 @@
#include <ostream>
#include <stdexcept>
#include <string>
-#include <type_traits>
namespace cm {
diff --git a/Tests/CMakeLib/testStringAlgorithms.cxx b/Tests/CMakeLib/testStringAlgorithms.cxx
index 1bb23df..78442ba 100644
--- a/Tests/CMakeLib/testStringAlgorithms.cxx
+++ b/Tests/CMakeLib/testStringAlgorithms.cxx
@@ -1,12 +1,11 @@
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
file Copyright.txt or https://cmake.org/licensing for details. */
-#include <cmConfigure.h> // IWYU pragma: keep
+#include "cmConfigure.h" // IWYU pragma: keep
#include <iostream>
#include <sstream>
#include <string>
-#include <type_traits>
#include <utility>
#include <vector>
diff --git a/Utilities/IWYU/mapping.imp b/Utilities/IWYU/mapping.imp
index 6443632..366c517 100644
--- a/Utilities/IWYU/mapping.imp
+++ b/Utilities/IWYU/mapping.imp
@@ -99,6 +99,7 @@
{ symbol: [ "std::enable_if<true, std::chrono::duration<long, std::ratio<60, 1> > >::type", private, "\"cmConfigure.h\"", public ] },
{ symbol: [ "std::enable_if<true, std::chrono::duration<long, std::ratio<1, 1000> > >::type", private, "\"cmConfigure.h\"", public ] },
{ symbol: [ "__gnu_cxx::__enable_if<true, bool>::__type", private, "\"cmConfigure.h\"", public ] },
+ { symbol: [ "std::remove_reference<std::basic_string<char, std::char_traits<char>, std::allocator<char> > &>::type", private, "\"cmConfigure.h\"", public ] },
{ symbol: [ "std::remove_reference<Defer &>::type", private, "\"cmConfigure.h\"", public ] },
# Wrappers for 3rd-party libraries