From be939cf169686b1c7bb883fe0f4fa2167b3c1a64 Mon Sep 17 00:00:00 2001 From: Kitaiti Makoto Date: Sat, 16 Jan 2021 00:59:07 +0900 Subject: [PATCH] Suppress clippy --- plume-common/src/utils.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plume-common/src/utils.rs b/plume-common/src/utils.rs index 53a70d7c..ad2f3c8b 100644 --- a/plume-common/src/utils.rs +++ b/plume-common/src/utils.rs @@ -60,6 +60,7 @@ fn to_inline(tag: Tag<'_>) -> Tag<'_> { struct HighlighterContext { content: Vec, } +#[allow(clippy::unnecessary_wraps)] fn highlight_code<'a>( context: &mut Option, evt: Event<'a>, @@ -119,6 +120,7 @@ fn highlight_code<'a>( _ => Some(vec![evt]), } } +#[allow(clippy::unnecessary_wraps)] fn flatten_text<'a>(state: &mut Option, evt: Event<'a>) -> Option>> { let (s, res) = match evt { Event::Text(txt) => match state.take() { @@ -137,6 +139,7 @@ fn flatten_text<'a>(state: &mut Option, evt: Event<'a>) -> Option( (state, inline): &mut (Vec>, bool), evt: Event<'a>,