From 9641e1b2cd45820102404d7a6bc6581f38d69210 Mon Sep 17 00:00:00 2001 From: Mathieu Aubin <15820228+mathieu-aubin@users.noreply.github.com> Date: Tue, 10 Sep 2024 05:36:34 -0400 Subject: [PATCH] fix warning: elided lifetime fixes 'warning: elided lifetime has a name' --- src/rows.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rows.rs b/src/rows.rs index 1d8dc44..7bb4d79 100644 --- a/src/rows.rs +++ b/src/rows.rs @@ -122,7 +122,7 @@ impl<'pixels, 'rows> DynamicRows<'pixels, 'rows> { Self { width, height, f_pixels: None, pixels, gamma } } - fn row_rgba<'px>(&'px self, temp_row: &'px mut [MaybeUninit], row: usize) -> &[RGBA] { + fn row_rgba<'px>(&'px self, temp_row: &'px mut [MaybeUninit], row: usize) -> &'px [RGBA] { match &self.pixels { PixelsSource::Pixels { rows, .. } => unsafe { std::slice::from_raw_parts(rows.as_slice()[row].0, self.width())