From 2d35cbfceace81a217cd0fbdae7a8777c7a6465e Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Thu, 11 Aug 2022 13:31:20 +0200 Subject: Refactor internal docs, code style of tokenizer --- src/subtokenize.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/subtokenize.rs') diff --git a/src/subtokenize.rs b/src/subtokenize.rs index 3d923d3..bf6a106 100644 --- a/src/subtokenize.rs +++ b/src/subtokenize.rs @@ -99,10 +99,7 @@ pub fn subtokenize(events: &mut Vec, parse_state: &ParseState) -> bool { state = tokenizer.push( (enter.point.index, enter.point.vs), (end.index, end.vs), - match state { - State::Next(func) => func, - _ => unreachable!("cannot be ok/nok"), - }, + state, ); link_index = link_curr.next; @@ -112,7 +109,6 @@ pub fn subtokenize(events: &mut Vec, parse_state: &ParseState) -> bool { divide_events(&mut map, events, index, &mut tokenizer.events); - // To do: check `tokenizer.events` if there is a deep content type? done = false; } } -- cgit