Browse Source

cmNinjaTargetGenerator: use `.clear()` to empty out some strings

Ben Boeckel 3 years ago
parent
commit
9123a0991f
1 changed files with 2 additions and 2 deletions
  1. 2 2
      Source/cmNinjaTargetGenerator.cxx

+ 2 - 2
Source/cmNinjaTargetGenerator.cxx

@@ -542,9 +542,9 @@ cmNinjaRule GetScanRule(
   // Scanning always uses a depfile for preprocessor dependencies.
   if (deptype == "msvc"_s) {
     rule.DepType = deptype;
-    rule.DepFile = "";
+    rule.DepFile.clear();
   } else {
-    rule.DepType = ""; // no deps= for multiple outputs
+    rule.DepType.clear(); // no deps= for multiple outputs
     rule.DepFile = "$DEP_FILE";
   }