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 Apr 1, 2024
1 parent 6bbd83f commit 06ad31a
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 @@ -374,7 +374,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 06ad31a

Please sign in to comment.