util/sample_format: use lifetime elision
This commit is contained in:
parent
e07c7ec4cd
commit
47f010a3cb
@ -149,7 +149,7 @@ impl Buffer {
|
|||||||
impl Index<usize> for Buffer {
|
impl Index<usize> for Buffer {
|
||||||
type Output = [u8];
|
type Output = [u8];
|
||||||
|
|
||||||
fn index<'a>(&'a self, index: usize) -> &'a [u8] {
|
fn index(&self, index: usize) -> &[u8] {
|
||||||
if index >= self.samples {
|
if index >= self.samples {
|
||||||
panic!("out of bounds");
|
panic!("out of bounds");
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user