Browse Source

clang-tidy: fix `modernize-use-auto` lints

Ben Boeckel 2 years ago
parent
commit
4489e9a85c

+ 1 - 1
Source/CPack/WiX/cmCPackWIXGenerator.cxx

@@ -1061,7 +1061,7 @@ std::string cmCPackWIXGenerator::GetRightmostExtension(
 
 std::string cmCPackWIXGenerator::PathToId(std::string const& path)
 {
-  id_map_t::const_iterator i = PathToIdMap.find(path);
+  auto i = PathToIdMap.find(path);
   if (i != PathToIdMap.end()) {
     return i->second;
   }

+ 1 - 1
Source/CPack/WiX/cmWIXPatch.cxx

@@ -25,7 +25,7 @@ bool cmWIXPatch::LoadFragments(std::string const& patchFilePath)
 void cmWIXPatch::ApplyFragment(std::string const& id,
                                cmWIXSourceWriter& writer)
 {
-  cmWIXPatchParser::fragment_map_t::iterator i = Fragments.find(id);
+  auto i = Fragments.find(id);
   if (i == Fragments.end()) {
     return;
   }

+ 1 - 1
Source/CPack/WiX/cmWIXShortcut.cxx

@@ -20,7 +20,7 @@ bool cmWIXShortcuts::EmitShortcuts(
   std::string const& cpackComponentName,
   cmWIXFilesSourceWriter& fileDefinitions) const
 {
-  shortcut_type_map_t::const_iterator i = this->Shortcuts.find(type);
+  auto i = this->Shortcuts.find(type);
 
   if (i == this->Shortcuts.end()) {
     return false;