Fix clippy lints by removing lifetimes

This commit is contained in:
Gwilym Kuiper 2021-06-25 22:18:40 +01:00
parent 90551b0ba1
commit 025f4f5a91

View file

@ -65,17 +65,17 @@ impl SoundChannel {
}
}
pub fn should_loop<'a>(&'a mut self) -> &'a mut Self {
pub fn should_loop(&mut self) -> &mut Self {
self.should_loop = true;
self
}
pub fn playback<'a>(&'a mut self, playback_speed: Num<usize, 8>) -> &'a mut Self {
pub fn playback(&mut self, playback_speed: Num<usize, 8>) -> &mut Self {
self.playback_speed = playback_speed;
self
}
pub fn panning<'a>(&'a mut self, panning: Num<i16, 4>) -> &'a mut Self {
pub fn panning(&mut self, panning: Num<i16, 4>) -> &mut Self {
debug_assert!(panning >= Num::new(-1), "panning value must be >= -1");
debug_assert!(panning <= Num::new(1), "panning value must be <= 1");
@ -83,7 +83,7 @@ impl SoundChannel {
self
}
pub fn volume<'a>(&'a mut self, volume: Num<i16, 4>) -> &'a mut Self {
pub fn volume(&mut self, volume: Num<i16, 4>) -> &mut Self {
assert!(volume <= Num::new(1), "volume must be <= 1");
assert!(volume >= Num::new(0), "volume must be >= 0");