================
@@ -185,10 +174,8 @@ static void groupDiagnostics(ArrayRef<const Record *> 
Diags,
   }
 
   // Assign unique ID numbers to the groups.
-  unsigned IDNo = 0;
-  for (std::map<std::string, GroupInfo>::iterator
-       I = DiagsInGroup.begin(), E = DiagsInGroup.end(); I != E; ++I, ++IDNo)
-    I->second.IDNo = IDNo;
+  for (auto [IdNo, Iter] : enumerate(DiagsInGroup))
+    Iter.second.IDNo = IdNo;
----------------
erichkeane wrote:

"are the values" doesn't mean "we didn't copy these and gave you a reference".  
So I don't think we can conclude my 5 minute look into the types is accurate 
based on that comment.

https://github.com/llvm/llvm-project/pull/115573
_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to