Use wrapping_add, not +, in one case

This commit is contained in:
Pyrex 2023-06-23 21:20:28 -07:00
parent ff86792d69
commit 03b42fd574

View File

@ -44,7 +44,7 @@ impl MovType {
fn merge(&self, old_value: Sample, new_value: Sample) -> Sample {
match self {
MovType::Mov => new_value,
MovType::Add => Sample(old_value.0 + new_value.0),
MovType::Add => Sample(old_value.0.wrapping_add(new_value.0)),
MovType::Xor => Sample(old_value.0 ^ new_value.0)
}
}