From e4638e257823e01408ac46211764470ec565f964 Mon Sep 17 00:00:00 2001 From: Basile Henry Date: Mon, 2 Nov 2020 22:31:51 +0100 Subject: CI: Use a work around to not hit the clippy issue --- abnf_to_pest/src/lib.rs | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'abnf_to_pest/src/lib.rs') diff --git a/abnf_to_pest/src/lib.rs b/abnf_to_pest/src/lib.rs index deddf54..627444a 100644 --- a/abnf_to_pest/src/lib.rs +++ b/abnf_to_pest/src/lib.rs @@ -42,9 +42,12 @@ impl Pretty for Node { nodes.iter().map(|x| x.pretty()), BoxDoc::space().append(BoxDoc::text("~ ")), ), - Repetition(rep) => { - rep.node().pretty().append(rep.repeat().pretty()) - } + Repetition(rep) => rep + .node() + .pretty() + // this repeat application is a temporary work-around for the clippy issue: + // https://github.com/rust-lang/rust-clippy/pull/5948 + .append(abnf::types::Repetition::repeat(rep).pretty()), Rulename(s) => BoxDoc::text(escape_rulename(s)), Group(n) => BoxDoc::text("(") .append(n.pretty().nest(4).group()) -- cgit v1.2.3