pub fn mem_size(&self) -> usize {
        let mut nodes = self.node_iter();
        let mut size = 0;
        // The first node is the head. Count the actual head size.
        size += std::mem::size_of::<Self>();
        nodes.next(); // And discard it from the iterator.

        for n in nodes {
            let layout = Node::layout_with_height(n.height);
            size += layout.size();
        }

        size
    }
/// This method counts the number of bytes of memory allocated in the rope. This is purely for
/// debugging.
///
/// Notes:
///
/// - This method (its existence, its signature and its return value) is not considered part of
///   the stable API provided by jumprope. This may disappear or change in point releases.
/// - This method walks the entire rope. It has time complexity O(n).
/// - If a rope is owned inside another structure, this method will double-count the bytes
///   stored in the rope's head.
This method counts the number of bytes of memory allocated in the rope. This is purely for
debugging.



This method (its existence, its signature and its return value) is not considered part of
the stable API provided by jumprope. This may disappear or change in point releases.
This method walks the entire rope. It has time complexity O(n).
If a rope is owned inside another structure, this method will double-count the bytes
stored in the rope's head.
This method counts the number of bytes of memory allocated in the rope . This is purely for debugging . This method ( its existence its signature and its return value ) is not considered part of the stable API provided by jumprope . This may disappear or change in point releases . This method walks the entire rope . It has time complexity O ( n ) . If a rope is owned inside another structure this method will double - count the bytes stored in the rope ' s head .
pub fn mem_size(&self) -> usize {
        let mut nodes = self.node_iter();
        let mut size = 0;
        // The first node is the head. Count the actual head size.
        size += std::mem::size_of::<Self>();
        nodes.next(); // And discard it from the iterator.
        for n in nodes {
            let layout = Node::layout_with_height(n.height);
            size += layout.size();
        }
        size
    }
pub fn mem_size ( & self ) -> usize { let mut nodes = self . node_iter ( ) ; let mut size = 0 ; // The first node is the head. Count the actual head size. size += std :: mem :: size_of :: < Self > ( ) ; nodes . next ( ) ; // And discard it from the iterator. for n in nodes { let layout = Node :: layout_with_height ( n . height ) ; size += layout . size ( ) ; } size }
This method counts the number of bytes of memory allocated in the rope.
This method counts the number of bytes of memory allocated in the rope .
&self