safety comment

This commit is contained in:
Christian Schwarz
2024-04-17 13:35:45 +00:00
parent 99056dde13
commit 717b7cb73e
@@ -54,6 +54,10 @@ impl<const N: usize> Buf<N> {
}
}
/// SAFETY:
///
/// The [`Self::allocation`] is stable becauses boxes are stable.
///
unsafe impl<const N: usize> tokio_epoll_uring::IoBuf for Buf<N> {
fn stable_ptr(&self) -> *const u8 {
self.allocation.as_ptr()