Skip to content

Commit 67f2ced

Browse files
committed
Give more information about the transmutation source type
1 parent d9b40ff commit 67f2ced

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/io/buf_read/fill_buf.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,6 @@ impl<'a, R: AsyncBufRead + Unpin + ?Sized> Future for FillBufFuture<'a, R> {
2727
// This is safe because:
2828
// 1. The buffer is valid for the lifetime of the reader.
2929
// 2. Output is unrelated to the wrapper (Self).
30-
result.map_ok(|buf| unsafe { std::mem::transmute::<_, &'a [u8]>(buf) })
30+
result.map_ok(|buf| unsafe { std::mem::transmute::<&'_ [u8], &'a [u8]>(buf) })
3131
}
3232
}

0 commit comments

Comments
 (0)