pub fn remove(&mut self, mut range: Range<usize>) {
        range.end = range.end.min(self.len_chars());
        if range.start >= range.end { return; }

        // We need to stick_end so we can delete entries.
        let mut cursor = self.cursor_at_char(range.start, true);
        unsafe { self.del_at_cursor(&mut cursor, range.end - range.start); }

        debug_assert_eq!(cursor.global_char_pos(self.head.height), range.start);
    }
/// Delete a span of unicode characters from the rope. The span is specified in unicode
/// characters, not bytes.
///
/// Any attempt to delete past the end of the rope will be silently ignored.
///
/// # Example
///
/// ```
/// # use jumprope::*;
/// let mut rope = JumpRope::from("Whoa dawg!");
/// rope.remove(4..9); // delete " dawg"
/// assert_eq!(rope.to_string(), "Whoa!");
/// ```
Delete a span of unicode characters from the rope. The span is specified in unicode
characters, not bytes.

Any attempt to delete past the end of the rope will be silently ignored.
Delete a span of unicode characters from the rope . The span is specified in unicode characters not bytes . Any attempt to delete past the end of the rope will be silently ignored .
pub fn remove(&mut self, mut range: Range<usize>) {
        range.end = range.end.min(self.len_chars());
        if range.start >= range.end { return; }
        // We need to stick_end so we can delete entries.
        let mut cursor = self.cursor_at_char(range.start, true);
        unsafe { self.del_at_cursor(&mut cursor, range.end - range.start); }
        debug_assert_eq!(cursor.global_char_pos(self.head.height), range.start);
    }
pub fn remove ( & mut self , mut range : Range < usize > ) { range . end = range . end . min ( self . len_chars ( ) ) ; if range . start >= range . end { return ; } // We need to stick_end so we can delete entries. let mut cursor = self . cursor_at_char ( range . start , true ) ; unsafe { self . del_at_cursor ( & mut cursor , range . end - range . start ) ; } debug_assert_eq ! ( cursor global_char_pos ( self head height ) range start ) ; }
Delete a span of unicode characters from the rope.
Delete a span of unicode characters from the rope .
&mut self
range
Range<usize>
example
None
use jumprope::*;
let mut rope = JumpRope::from("Whoa dawg!");
rope.remove(4..9); // delete " dawg"
assert_eq!(rope.to_string(), "Whoa!");
```
let mut rope = JumpRope :: from ( " Whoa dawg! " ) ; rope . remove ( 4 .. 9 ) ; // delete " dawg " assert_eq! ( rope . to_string () " Whoa! " ) ; ` ` `