fn make_fat_pointer(octets: *const u8, n_labels: usize, wire_len: usize) -> *const Name {
        // NOTE: if/when std::ptr::from_raw_parts becomes available, use
        // it instead. This is how the slice-dst crate works, and I'm
        // not aware of a better way of doing this given Rust's current
        // lack of support for custom DSTs, but this is uncomfortably
        // hacky and, I think, relies on the implementation details.
        ptr::slice_from_raw_parts(octets, n_labels + wire_len) as *const Name
    }
/// Converts a pointer to a buffer in which a name has been
/// initialized and size information into a const pointer to a
/// `Name`. Since `Name` is a dynamically sized type, this will be a
/// fat pointer that includes the size information for the `Name`.
///
/// # Safety
///
/// This operation is not unsafe in itself, but if you want to
/// actually _use_ the returned pointer/convert it to a reference,
/// you need to make sure that
///
/// * the buffer has been initialized to a valid `Name` value;
/// * the memory region lies within a single allocation;
/// * `n_labels` and `wire_len` are correct; and
/// * the `Name` object must be no larger than [`isize::MAX`]
///   (which will be satisfied if the first condition is met).
/// * the data is not mutated during the lifetime of the created
///   reference.
Converts a pointer to a buffer in which a name has been
initialized and size information into a const pointer to a
`Name`. Since `Name` is a dynamically sized type, this will be a
fat pointer that includes the size information for the `Name`.
Converts a pointer to a buffer in which a name has been initialized and size information into a const pointer to a ` Name ` . Since ` Name ` is a dynamically sized type this will be a fat pointer that includes the size information for the ` Name ` .
fn make_fat_pointer(octets: *const u8, n_labels: usize, wire_len: usize) -> *const Name {
        // NOTE: if/when std::ptr::from_raw_parts becomes available, use
        // it instead. This is how the slice-dst crate works, and I'm
        // not aware of a better way of doing this given Rust's current
        // lack of support for custom DSTs, but this is uncomfortably
        // hacky and, I think, relies on the implementation details.
        ptr::slice_from_raw_parts(octets, n_labels + wire_len) as *const Name
    }
fn make_fat_pointer ( octets : * const u8 , n_labels : usize , wire_len : usize ) -> * const Name { // NOTE: if/when std::ptr::from_raw_parts becomes available, use // it instead. This is how the slice-dst crate works, and I'm // not aware of a better way of doing this given Rust's current // lack of support for custom DSTs, but this is uncomfortably // hacky and, I think, relies on the implementation details. ptr :: slice_from_raw_parts ( octets , n_labels + wire_len ) as * const Name }
Converts a pointer to a buffer in which a name has been
initialized and size information into a const pointer to a
`Name`.
Converts a pointer to a buffer in which a name has been initialized and size information into a const pointer to a ` Name ` .
octets
*const u8
n_labels
usize
wire_len
usize
octets
*const u8
n_labels
usize
wire_len
usize
safety
This operation is not unsafe in itself, but if you want to
actually _use_ the returned pointer/convert it to a reference,
you need to make sure that

the buffer has been initialized to a valid `Name` value;
the memory region lies within a single allocation;
`n_labels` and `wire_len` are correct; and
the `Name` object must be no larger than [`isize::MAX`]
(which will be satisfied if the first condition is met).
the data is not mutated during the lifetime of the created
reference.
This operation is not unsafe in itself but if you want to actually _use_ the returned pointer / convert it to a reference you need to make sure that the buffer has been initialized to a valid ` Name ` value ; the memory region lies within a single allocation ; ` n_labels ` and ` wire_len ` are correct ; and the ` Name ` object must be no larger than [ ` isize :: MAX ` ] ( which will be satisfied if the first condition is met ) . the data is not mutated during the lifetime of the created reference .