pub fn ref_to_offset<T>(&self, ptr: &T) -> Option<u32> {
        if self.is_ptr_inside(ptr as *const T) {
            Some(((ptr as *const T as usize) - (self.start as usize)) as u32)
        } else {
            None
        }
    }
/// If this pointer refers to an object allocated from within this heap,
/// return a u32 offset which can be used to identify it on 64-bit
/// systems where the heap will never exceed 4GB.
If this pointer refers to an object allocated from within this heap,
return a u32 offset which can be used to identify it on 64-bit
systems where the heap will never exceed 4GB.
If this pointer refers to an object allocated from within this heap return a u32 offset which can be used to identify it on 64 - bit systems where the heap will never exceed 4GB .
pub fn ref_to_offset<T>(&self, ptr: &T) -> Option<u32> {
        if self.is_ptr_inside(ptr as *const T) {
            Some(((ptr as *const T as usize) - (self.start as usize)) as u32)
        } else {
            None
        }
    }
pub fn ref_to_offset < T > ( & self , ptr : & T ) -> Option < u32 > { if self . is_ptr_inside ( ptr as * const T ) { Some ( ( ( ptr as * const T as usize ) - ( self . start as usize ) ) as u32 ) } else { None } }
If this pointer refers to an object allocated from within this heap,
return a u32 offset which can be used to identify it on 64-bit
systems where the heap will never exceed 4GB.
If this pointer refers to an object allocated from within this heap return a u32 offset which can be used to identify it on 64 - bit systems where the heap will never exceed 4GB .
&self
ptr
&T
&self
ptr
&T