From ae0f12e668cfd37728aad907c813431595e6cc1b Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Tue, 19 Jul 2022 15:36:21 +0200 Subject: Use `edit_map` in `subtokenize` --- src/util/edit_map.rs | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'src/util') diff --git a/src/util/edit_map.rs b/src/util/edit_map.rs index eda767a..90ff483 100644 --- a/src/util/edit_map.rs +++ b/src/util/edit_map.rs @@ -107,20 +107,7 @@ impl EditMap { next_events.append(append); } - if !add.is_empty() { - let append = &mut add; - let mut index = 0; - - while index < append.len() { - let event = &mut append[index]; - assert!(event.previous.is_none(), "to do?"); - assert!(event.next.is_none(), "to do?"); - index += 1; - } - - next_events.append(append); - } - + next_events.append(&mut add); start = at + remove; index += 1; } -- cgit