Browse Source

Refactoring: rename "cm_static_string_view.hxx" as <cmext/string_view>

Marc Chevrier 5 years ago
parent
commit
8d4a9ee398
38 changed files with 43 additions and 66 deletions
  1. 0 1
      Source/CMakeLists.txt
  2. 1 1
      Source/CTest/cmCTestBuildCommand.cxx
  3. 1 1
      Source/CTest/cmCTestConfigureCommand.cxx
  4. 1 2
      Source/CTest/cmCTestCoverageCommand.cxx
  5. 1 1
      Source/CTest/cmCTestHandlerCommand.cxx
  6. 1 1
      Source/CTest/cmCTestMemCheckCommand.cxx
  7. 1 2
      Source/CTest/cmCTestSubmitCommand.cxx
  8. 1 1
      Source/CTest/cmCTestTestCommand.cxx
  9. 1 1
      Source/CTest/cmCTestTestHandler.cxx
  10. 1 2
      Source/CTest/cmCTestUploadCommand.cxx
  11. 1 2
      Source/cmArgumentParser.h
  12. 1 2
      Source/cmCTest.cxx
  13. 1 2
      Source/cmConfigureFileCommand.cxx
  14. 2 2
      Source/cmCoreTryCompile.cxx
  15. 1 2
      Source/cmExecuteProcessCommand.cxx
  16. 1 2
      Source/cmExportCommand.cxx
  17. 1 1
      Source/cmFileCommand.cxx
  18. 1 2
      Source/cmForEachCommand.cxx
  19. 1 2
      Source/cmFunctionCommand.cxx
  20. 1 2
      Source/cmGeneratorExpressionDAGChecker.cxx
  21. 1 2
      Source/cmGeneratorExpressionNode.cxx
  22. 1 2
      Source/cmGeneratorTarget.cxx
  23. 1 2
      Source/cmIfCommand.cxx
  24. 1 2
      Source/cmInstallCommand.cxx
  25. 1 1
      Source/cmInstallCommandArguments.cxx
  26. 1 2
      Source/cmListCommand.cxx
  27. 1 2
      Source/cmMacroCommand.cxx
  28. 1 1
      Source/cmMakefile.cxx
  29. 1 2
      Source/cmMessageCommand.cxx
  30. 1 2
      Source/cmString.hxx
  31. 1 2
      Source/cmStringCommand.cxx
  32. 1 2
      Source/cmSubcommandTable.h
  33. 1 2
      Source/cmWhileCommand.cxx
  34. 1 1
      Source/cmake.cxx
  35. 1 2
      Tests/CMakeLib/testArgumentParser.cxx
  36. 1 2
      Tests/CMakeLib/testString.cxx
  37. 2 1
      Utilities/std/CMakeLists.txt
  38. 5 4
      Utilities/std/cmext/string_view

+ 0 - 1
Source/CMakeLists.txt

@@ -698,7 +698,6 @@ set(SRCS
   cmWriteFileCommand.cxx
   cmWriteFileCommand.h
 
-  cm_static_string_view.hxx
   cm_get_date.h
   cm_get_date.c
   cm_utf8.h

+ 1 - 1
Source/CTest/cmCTestBuildCommand.cxx

@@ -5,7 +5,7 @@
 #include <cstring>
 #include <sstream>
 
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmCTest.h"
 #include "cmCTestBuildHandler.h"

+ 1 - 1
Source/CTest/cmCTestConfigureCommand.cxx

@@ -6,7 +6,7 @@
 #include <sstream>
 #include <vector>
 
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmCTest.h"
 #include "cmCTestConfigureHandler.h"

+ 1 - 2
Source/CTest/cmCTestCoverageCommand.cxx

@@ -5,8 +5,7 @@
 #include <set>
 
 #include <cmext/algorithm>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmCTest.h"
 #include "cmCTestCoverageHandler.h"

+ 1 - 1
Source/CTest/cmCTestHandlerCommand.cxx

@@ -7,7 +7,7 @@
 #include <cstring>
 #include <sstream>
 
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmCTest.h"
 #include "cmCTestGenericHandler.h"

+ 1 - 1
Source/CTest/cmCTestMemCheckCommand.cxx

@@ -2,7 +2,7 @@
    file Copyright.txt or https://cmake.org/licensing for details.  */
 #include "cmCTestMemCheckCommand.h"
 
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmCTest.h"
 #include "cmCTestMemCheckHandler.h"

+ 1 - 2
Source/CTest/cmCTestSubmitCommand.cxx

@@ -9,8 +9,7 @@
 #include <cm/memory>
 #include <cm/vector>
 #include <cmext/algorithm>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmCTest.h"
 #include "cmCTestSubmitHandler.h"

+ 1 - 1
Source/CTest/cmCTestTestCommand.cxx

@@ -6,7 +6,7 @@
 #include <cstdlib>
 #include <sstream>
 
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmCTest.h"
 #include "cmCTestGenericHandler.h"

+ 1 - 1
Source/CTest/cmCTestTestHandler.cxx

@@ -20,13 +20,13 @@
 #include <cm/memory>
 #include <cm/string_view>
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/FStream.hxx"
 #include <cmsys/Base64.h>
 #include <cmsys/Directory.hxx>
 #include <cmsys/RegularExpression.hxx>
 
-#include "cm_static_string_view.hxx"
 #include "cm_utf8.h"
 
 #include "cmCTest.h"

+ 1 - 2
Source/CTest/cmCTestUploadCommand.cxx

@@ -6,8 +6,7 @@
 #include <sstream>
 
 #include <cm/vector>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmCTest.h"
 #include "cmCTestUploadHandler.h"

+ 1 - 2
Source/cmArgumentParser.h

@@ -12,8 +12,7 @@
 #include <vector>
 
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 namespace ArgumentParser {
 

+ 1 - 2
Source/cmCTest.cxx

@@ -19,6 +19,7 @@
 #include <cm/memory>
 #include <cm/string_view>
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/Base64.h"
 #include "cmsys/Directory.hxx"
@@ -36,8 +37,6 @@
 #  include <unistd.h> // IWYU pragma: keep
 #endif
 
-#include "cm_static_string_view.hxx"
-
 #include "cmCTestBuildAndTestHandler.h"
 #include "cmCTestBuildHandler.h"
 #include "cmCTestConfigureHandler.h"

+ 1 - 2
Source/cmConfigureFileCommand.cxx

@@ -5,8 +5,7 @@
 #include <set>
 
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmExecutionStatus.h"
 #include "cmMakefile.h"

+ 2 - 2
Source/cmCoreTryCompile.cxx

@@ -8,9 +8,9 @@
 #include <sstream>
 #include <utility>
 
-#include "cmsys/Directory.hxx"
+#include <cmext/string_view>
 
-#include "cm_static_string_view.hxx"
+#include "cmsys/Directory.hxx"
 
 #include "cmExportTryCompileFileGenerator.h"
 #include "cmGlobalGenerator.h"

+ 1 - 2
Source/cmExecuteProcessCommand.cxx

@@ -10,11 +10,10 @@
 #include <vector>
 
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/Process.h"
 
-#include "cm_static_string_view.hxx"
-
 #include "cmArgumentParser.h"
 #include "cmExecutionStatus.h"
 #include "cmMakefile.h"

+ 1 - 2
Source/cmExportCommand.cxx

@@ -8,11 +8,10 @@
 
 #include <cm/memory>
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/RegularExpression.hxx"
 
-#include "cm_static_string_view.hxx"
-
 #include "cmArgumentParser.h"
 #include "cmExecutionStatus.h"
 #include "cmExportBuildAndroidMKGenerator.h"

+ 1 - 1
Source/cmFileCommand.cxx

@@ -17,13 +17,13 @@
 
 #include <cm/memory>
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/FStream.hxx"
 #include "cmsys/Glob.hxx"
 #include "cmsys/RegularExpression.hxx"
 
 #include "cm_kwiml.h"
-#include "cm_static_string_view.hxx"
 #include "cm_sys_stat.h"
 
 #include "cmAlgorithms.h"

+ 1 - 2
Source/cmForEachCommand.cxx

@@ -18,8 +18,7 @@
 
 #include <cm/memory>
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmExecutionStatus.h"
 #include "cmFunctionBlocker.h"

+ 1 - 2
Source/cmFunctionCommand.cxx

@@ -7,8 +7,7 @@
 #include <cm/memory>
 #include <cm/string_view>
 #include <cmext/algorithm>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmExecutionStatus.h"
 #include "cmFunctionBlocker.h"

+ 1 - 2
Source/cmGeneratorExpressionDAGChecker.cxx

@@ -7,8 +7,7 @@
 #include <utility>
 
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmGeneratorExpressionContext.h"
 #include "cmGeneratorExpressionEvaluator.h"

+ 1 - 2
Source/cmGeneratorExpressionNode.cxx

@@ -17,12 +17,11 @@
 #include <cm/string_view>
 #include <cm/vector>
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/RegularExpression.hxx"
 #include "cmsys/String.h"
 
-#include "cm_static_string_view.hxx"
-
 #include "cmAlgorithms.h"
 #include "cmGeneratorExpression.h"
 #include "cmGeneratorExpressionContext.h"

+ 1 - 2
Source/cmGeneratorTarget.cxx

@@ -18,11 +18,10 @@
 #include <cm/memory>
 #include <cm/string_view>
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/RegularExpression.hxx"
 
-#include "cm_static_string_view.hxx"
-
 #include "cmAlgorithms.h"
 #include "cmComputeLinkInformation.h"
 #include "cmCustomCommand.h"

+ 1 - 2
Source/cmIfCommand.cxx

@@ -7,8 +7,7 @@
 
 #include <cm/memory>
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmConditionEvaluator.h"
 #include "cmExecutionStatus.h"

+ 1 - 2
Source/cmInstallCommand.cxx

@@ -8,11 +8,10 @@
 #include <utility>
 
 #include <cm/memory>
+#include <cmext/string_view>
 
 #include "cmsys/Glob.hxx"
 
-#include "cm_static_string_view.hxx"
-
 #include "cmArgumentParser.h"
 #include "cmExecutionStatus.h"
 #include "cmExportSet.h"

+ 1 - 1
Source/cmInstallCommandArguments.cxx

@@ -4,7 +4,7 @@
 
 #include <utility>
 
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmRange.h"
 #include "cmSystemTools.h"

+ 1 - 2
Source/cmListCommand.cxx

@@ -17,11 +17,10 @@
 
 #include <cm/memory>
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/RegularExpression.hxx"
 
-#include "cm_static_string_view.hxx"
-
 #include "cmAlgorithms.h"
 #include "cmExecutionStatus.h"
 #include "cmGeneratorExpression.h"

+ 1 - 2
Source/cmMacroCommand.cxx

@@ -8,8 +8,7 @@
 #include <cm/memory>
 #include <cm/string_view>
 #include <cmext/algorithm>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmExecutionStatus.h"
 #include "cmFunctionBlocker.h"

+ 1 - 1
Source/cmMakefile.cxx

@@ -18,13 +18,13 @@
 #include <cm/optional>
 #include <cm/vector>
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/FStream.hxx"
 #include "cmsys/RegularExpression.hxx"
 
 #include "cm_jsoncpp_value.h"
 #include "cm_jsoncpp_writer.h"
-#include "cm_static_string_view.hxx"
 #include "cm_sys_stat.h"
 
 #include "cmCommandArgumentParserHelper.h"

+ 1 - 2
Source/cmMessageCommand.cxx

@@ -6,8 +6,7 @@
 #include <utility>
 
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmExecutionStatus.h"
 #include "cmMakefile.h"

+ 1 - 2
Source/cmString.hxx

@@ -16,8 +16,7 @@
 #include <utility>
 
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 namespace cm {
 

+ 1 - 2
Source/cmStringCommand.cxx

@@ -11,11 +11,10 @@
 #include <memory>
 
 #include <cm/iterator>
+#include <cmext/string_view>
 
 #include "cmsys/RegularExpression.hxx"
 
-#include "cm_static_string_view.hxx"
-
 #include "cmCryptoHash.h"
 #include "cmExecutionStatus.h"
 #include "cmGeneratorExpression.h"

+ 1 - 2
Source/cmSubcommandTable.h

@@ -11,8 +11,7 @@
 #include <vector>
 
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 class cmExecutionStatus;
 

+ 1 - 2
Source/cmWhileCommand.cxx

@@ -7,8 +7,7 @@
 
 #include <cm/memory>
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmConditionEvaluator.h"
 #include "cmExecutionStatus.h"

+ 1 - 1
Source/cmake.cxx

@@ -19,12 +19,12 @@
 #endif
 
 #include <cmext/algorithm>
+#include <cmext/string_view>
 
 #include "cmsys/FStream.hxx"
 #include "cmsys/Glob.hxx"
 #include "cmsys/RegularExpression.hxx"
 
-#include "cm_static_string_view.hxx"
 #include "cm_sys_stat.h"
 
 #include "cmCommands.h"

+ 1 - 2
Tests/CMakeLib/testArgumentParser.cxx

@@ -7,8 +7,7 @@
 #include <vector>
 
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmArgumentParser.h"
 

+ 1 - 2
Tests/CMakeLib/testString.cxx

@@ -12,8 +12,7 @@
 #include <utility>
 
 #include <cm/string_view>
-
-#include "cm_static_string_view.hxx"
+#include <cmext/string_view>
 
 #include "cmString.hxx"
 

+ 2 - 1
Utilities/std/CMakeLists.txt

@@ -9,6 +9,7 @@ set(SRCS cm/bits/string_view.cxx
          cm/optional
          cm/shared_mutex
          cm/string_view
-         cm/utility)
+         cm/utility
+         cmext/string_view)
 
 add_library(cmstd STATIC ${SRCS})

+ 5 - 4
Source/cm_static_string_view.hxx → Utilities/std/cmext/string_view

@@ -1,9 +1,10 @@
+// -*-c++-*-
+// vim: set ft=cpp:
+
 /* Distributed under the OSI-approved BSD 3-Clause License.  See accompanying
    file Copyright.txt or https://cmake.org/licensing for details.  */
-#ifndef cm_static_string_view_hxx
-#define cm_static_string_view_hxx
-
-#include "cmConfigure.h" // IWYU pragma: keep
+#ifndef cmext_string_view
+#define cmext_string_view
 
 #include <cstddef>