Skip to content

Commit

Permalink
Use Vec::with_capacity in NoiseModel::new
Browse files Browse the repository at this point in the history
  • Loading branch information
FreezyLemon committed Mar 31, 2024
1 parent 02ab2ea commit 4d43424
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/diff/solver.rs
Original file line number Diff line number Diff line change
Expand Up @@ -380,7 +380,7 @@ impl NoiseModel {
NoiseModelState::new(n + 1),
NoiseModelState::new(n + 1),
];
let mut coords = Vec::new();
let mut coords = Vec::with_capacity(n);

let neg_lag = -(NOISE_MODEL_LAG as isize);
for y in neg_lag..=0 {
Expand Down

0 comments on commit 4d43424

Please sign in to comment.