Switch zip to zip_equal where possible (#6389)

There are two uses I'm not converting here, that seem to want the
"shortest" behavior. For everything else, I'm going to `zip_equal` since
it's more restrictive.

I wish `zip` were named `zip_shortest`.
This commit is contained in:
Jon Ross-Perkins authored and GitHub committed 2025-11-18 00:28:06 +00:00
1 parent 205aea9a3e
commit fbc7690157
13 files changed
+34 -31

No files matched your search

+1 -1
View File
@@ -654,7 +654,7 @@ class Stringifier {
step_stack_->PushString("}");
llvm::ListSeparator sep;
for (auto [field, value_inst_id] :
llvm::reverse(llvm::zip(fields, field_values))) {
llvm::reverse(llvm::zip_equal(fields, field_values))) {
step_stack_->Push(".", field.name_id, " = ", value_inst_id, &sep);
}
}