Skip to content

Commit 119abc6

Browse files
committed
[MoveOnlyAddressChecker] NFC: Used helper.
Used the TypeTreeLeafTypeRange::setBits helper rather than looping over the range and setting the bits in place.
1 parent ff7aa3c commit 119abc6

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

lib/SILOptimizer/Mandatory/MoveOnlyAddressCheckerUtils.cpp

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -667,9 +667,7 @@ struct UseState {
667667

668668
void recordLivenessUse(SILInstruction *inst, TypeTreeLeafTypeRange range) {
669669
auto &bits = getOrCreateLivenessUse(inst);
670-
for (auto element : range.getRange()) {
671-
bits.set(element);
672-
}
670+
range.setBits(bits);
673671
}
674672

675673
/// Returns true if this is a terminator instruction that although it doesn't

0 commit comments

Comments
 (0)