[][src]Function deep_safe_drop::deep_safe_drop

pub fn deep_safe_drop<RootNode: ?Sized, Link>(root: &mut RootNode) where
    RootNode: DeepSafeDrop<Link>,
    Link: DerefMut,
    Link::Target: DeepSafeDrop<Link>, 

To be called from your Drop::drop implementations, to ensure that stack overflow is avoided.

The RootNode type may be different than the primary Link::Target node type, when possible, which might be convenient. Or, they can be the same.