reencode: take the split units whole, as clippy asks

clippy's drain_collect: draining all of split_units into a new Vec of the same
type; std::mem::take moves them without a new allocation.
This commit is contained in:
Anees Iqbal committed 2026-11-14 02:06:05 -08:00
1 parent 6921672095
commit 82ef730d1d
1 file changed
+1 -1
@@ -140,7 +140,7 @@ impl CommandBufferShared {
let open: BTreeSet<usize> = (state.recorded[state.unjudged_parts()..].iter())
.map(|part| part.encoder)
.collect();
let split: Vec<Vec<usize>> = state.split_units.drain(..).collect();
let split = std::mem::take(&mut state.split_units);
let splitting: BTreeSet<usize> = split.iter().flatten().copied().collect();
let mut units = Vec::new();
for unit in split {