From 8162222295d71ea7fd9270c7b3b9497b91db3f1f Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Wed, 10 Aug 2022 09:16:36 +0200 Subject: Rename `State::Fn` to `State::Next` --- src/construct/partial_title.rs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'src/construct/partial_title.rs') diff --git a/src/construct/partial_title.rs b/src/construct/partial_title.rs index 1d3e9b2..9521d32 100644 --- a/src/construct/partial_title.rs +++ b/src/construct/partial_title.rs @@ -50,7 +50,7 @@ pub fn start(tokenizer: &mut Tokenizer) -> State { tokenizer.enter(tokenizer.tokenize_state.token_2.clone()); tokenizer.consume(); tokenizer.exit(tokenizer.tokenize_state.token_2.clone()); - State::Fn(StateName::TitleBegin) + State::Next(StateName::TitleBegin) } _ => State::Nok, } @@ -98,7 +98,7 @@ pub fn at_break(tokenizer: &mut Tokenizer) -> State { State::Nok } Some(b'\n') => { - let state_name = space_or_tab_eol_with_options( + let name = space_or_tab_eol_with_options( tokenizer, EolOptions { content_type: Some(ContentType::String), @@ -107,9 +107,9 @@ pub fn at_break(tokenizer: &mut Tokenizer) -> State { ); tokenizer.attempt( - state_name, - State::Fn(StateName::TitleAfterEol), - State::Fn(StateName::TitleAtBlankLine), + name, + State::Next(StateName::TitleAfterEol), + State::Next(StateName::TitleAtBlankLine), ) } Some(b'"' | b'\'' | b')') @@ -166,7 +166,7 @@ pub fn inside(tokenizer: &mut Tokenizer) -> State { } Some(byte) => { tokenizer.consume(); - State::Fn(if matches!(byte, b'\\') { + State::Next(if matches!(byte, b'\\') { StateName::TitleEscape } else { StateName::TitleInside @@ -185,7 +185,7 @@ pub fn escape(tokenizer: &mut Tokenizer) -> State { match tokenizer.current { Some(b'"' | b'\'' | b')') => { tokenizer.consume(); - State::Fn(StateName::TitleInside) + State::Next(StateName::TitleInside) } _ => inside(tokenizer), } -- cgit