From a613b6e9b2b72a94c2d3b7f2c1792850202e7dc1 Mon Sep 17 00:00:00 2001 From: Simon Gardling Date: Thu, 1 Apr 2021 09:29:32 -0400 Subject: [PATCH] clippy --- src/model.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/model.rs b/src/model.rs index cb7d80e..b0a3f3b 100644 --- a/src/model.rs +++ b/src/model.rs @@ -158,7 +158,7 @@ impl Model { diffusivity: usize, ) -> Self { let particles_per_grid = (n_particles as f64 / n_populations as f64).ceil() as usize; - let n_particles = particles_per_grid * n_populations; + let _n_particles = particles_per_grid * n_populations; let mut rng = rand::thread_rng(); @@ -180,7 +180,7 @@ impl Model { } let mut grids: Vec = Vec::new(); - for _ in (0..n_populations) { + for _ in 0..n_populations { let agents = (0..particles_per_grid) .map(|i| Agent::new(width, height, i / particles_per_grid, &mut rng, i)).collect(); grids.push(Grid::new(width, height, &mut rng, agents));