pub unsafe fn callback_ret_buffer<T: BufferValue>(
ptr: *mut u8,
len: usize,
) -> Result<T, ForeignError>Expand description
Adopt and decode a value buffer a vtable entry wrote to its
out_ptr/out_len slots.
§Errors
Returns a MARSHAL_ERROR_CODE failure for a null pointer with a
non-zero length or a malformed buffer.
§Safety
Same contract as callback_ret_bytes, and every object token in the
buffer must carry an unadopted reference (see
BufferValue::read_value).