[llvm] Use range-based for loops (NFC)

This commit is contained in:
Kazu Hirata
2021-11-18 09:09:52 -08:00
parent 7796d81ae8
commit 7ca14f6044
10 changed files with 29 additions and 46 deletions

View File

@@ -973,9 +973,8 @@ void ModuleBitcodeWriter::writeTypeTable() {
// STRUCT: [ispacked, eltty x N]
TypeVals.push_back(ST->isPacked());
// Output all of the element types.
for (StructType::element_iterator I = ST->element_begin(),
E = ST->element_end(); I != E; ++I)
TypeVals.push_back(VE.getTypeID(*I));
for (Type *ET : ST->elements())
TypeVals.push_back(VE.getTypeID(ET));
if (ST->isLiteral()) {
Code = bitc::TYPE_CODE_STRUCT_ANON;