style(format): iterate the chunk index in BlockGeometry::place
clippy's needless_range_loop, missed before the B2ND streaming commit. Co-Authored-By: Claude Opus 5.5 (1M context) <[email protected]>
This commit is contained in:
@@ -1014,9 +1014,9 @@ impl BlockGeometry<'_> {
|
||||
let nd = self.nd;
|
||||
unravel(b, self.blocks_in_chunk, &mut p.bidx);
|
||||
let mut empty = false;
|
||||
for i in 0..nd.shape.len() {
|
||||
for (i, &c) in cidx.iter().enumerate() {
|
||||
let in_chunk = p.bidx[i] * nd.blockshape[i];
|
||||
p.gstart[i] = cidx[i] * nd.chunkshape[i] + in_chunk;
|
||||
p.gstart[i] = c * nd.chunkshape[i] + in_chunk;
|
||||
let lim_chunk = nd.chunkshape[i].saturating_sub(in_chunk);
|
||||
let lim_shape = nd.shape[i].saturating_sub(p.gstart[i]);
|
||||
p.valid[i] = nd.blockshape[i].min(lim_chunk).min(lim_shape);
|
||||
|
||||
Reference in New Issue
Block a user