Removed branching

This commit is contained in:
MaxOhn
2021-01-08 12:26:59 +01:00
parent 0d72f28fc7
commit 238e33c660
9 changed files with 21 additions and 42 deletions
-17
View File
@@ -129,21 +129,4 @@ mod tests {
);
}
}
#[test]
fn wack_map() {
let file = match File::open("E:/Games/osu!/beatmaps/1443309.osu") {
Ok(file) => file,
Err(why) => panic!("Could not open file: {}", why),
};
let map = match Beatmap::parse(file) {
Ok(map) => map,
Err(why) => panic!("Error while parsing map: {}", why),
};
let stars = stars(&map, 0);
println!("Stars: {}", stars);
}
}
+1
View File
@@ -43,6 +43,7 @@ impl Strain {
#[inline]
pub(crate) fn save_current_peak(&mut self) {
// TODO: Remove branching
if self.prev_time.is_some() {
self.strain_peaks.push(self.current_section_peak);
}