From c9f75249b83839130ffbc3b6dd175b0e31008cb7 Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Mon, 18 Jul 2022 13:27:16 +0200 Subject: Refactor examples of states --- src/construct/partial_label.rs | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) (limited to 'src/construct/partial_label.rs') diff --git a/src/construct/partial_label.rs b/src/construct/partial_label.rs index f380c7d..b1d02e8 100644 --- a/src/construct/partial_label.rs +++ b/src/construct/partial_label.rs @@ -93,7 +93,8 @@ struct Info { /// Before a label. /// /// ```markdown -/// |[a] +/// > | [a] +/// ^ /// ``` pub fn start(tokenizer: &mut Tokenizer, code: Code, options: Options) -> StateFnResult { match code { @@ -118,8 +119,8 @@ pub fn start(tokenizer: &mut Tokenizer, code: Code, options: Options) -> StateFn /// In a label, at something. /// /// ```markdown -/// [|a] -/// [a|] +/// > | [a] +/// ^ /// ``` fn at_break(tokenizer: &mut Tokenizer, code: Code, mut info: Info) -> StateFnResult { match code { @@ -162,7 +163,8 @@ fn at_break(tokenizer: &mut Tokenizer, code: Code, mut info: Info) -> StateFnRes /// In a label, in text. /// /// ```markdown -/// [a|b] +/// > | [a] +/// ^ /// ``` fn label(tokenizer: &mut Tokenizer, code: Code, mut info: Info) -> StateFnResult { match code { @@ -201,7 +203,8 @@ fn label(tokenizer: &mut Tokenizer, code: Code, mut info: Info) -> StateFnResult /// After `\` in a label. /// /// ```markdown -/// [a\|[b] +/// > | [a\*a] +/// ^ /// ``` fn escape(tokenizer: &mut Tokenizer, code: Code, mut info: Info) -> StateFnResult { match code { -- cgit