From ce632f1093916c63ed959a1aab9d87c79fbd0385 Mon Sep 17 00:00:00 2001 From: Rutherther Date: Sat, 1 Nov 2025 12:44:13 +0100 Subject: [PATCH] fix(lib): do not take mut self in population.iter() --- codes/eoa_lib/src/replacement.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codes/eoa_lib/src/replacement.rs b/codes/eoa_lib/src/replacement.rs index 9cc6c5d4f00fc7fc182000594fb30d0b3681b9e5..853baf86092f6140fcb9ec2c0022e80a705ee2a2 100644 --- a/codes/eoa_lib/src/replacement.rs +++ b/codes/eoa_lib/src/replacement.rs @@ -117,7 +117,7 @@ impl EvaluatedPopulation { self.population.append(&mut offsprings.population); } - pub fn iter(&mut self) -> impl Iterator> { + pub fn iter(&self) -> impl Iterator> { self.population.iter() }