Przeglądaj źródła

multiboot2: fix wrong lifetime bound

Philipp Schuster 10 miesięcy temu
rodzic
commit
94201bba45
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      multiboot2/src/tag_trait.rs

+ 1 - 1
multiboot2/src/tag_trait.rs

@@ -51,7 +51,7 @@ pub trait TagTrait: Pointee {
     /// Callers must be sure that the "size" field of the provided [`Tag`] is
     /// sane and the underlying memory valid. The implementation of this trait
     /// **must have** a correct [`Self::dst_size`] implementation.
-    unsafe fn from_base_tag<'a>(tag: &Tag) -> &'a Self {
+    unsafe fn from_base_tag(tag: &Tag) -> &Self {
         let ptr = core::ptr::addr_of!(*tag);
         let ptr = ptr_meta::from_raw_parts(ptr.cast(), Self::dst_size(tag));
         &*ptr