From a69a7ab58565a5bbb8a1fbe6f32d801187c10500 Mon Sep 17 00:00:00 2001 From: Bruce Mitchener Date: Tue, 6 Feb 2024 01:22:32 +0700 Subject: [PATCH] Fix formatting error detected by rustfmt --- fluent-syntax/src/serializer.rs | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/fluent-syntax/src/serializer.rs b/fluent-syntax/src/serializer.rs index 70e5a5de..628018f2 100644 --- a/fluent-syntax/src/serializer.rs +++ b/fluent-syntax/src/serializer.rs @@ -21,7 +21,7 @@ //! assert_eq!(ftl, serialized); //! ``` -use crate::{ast::*, parser::Slice, parser::matches_fluent_ws}; +use crate::{ast::*, parser::matches_fluent_ws, parser::Slice}; use std::fmt::Write; /// Serializes an abstract syntax tree representing a Fluent Translation List into a @@ -118,11 +118,7 @@ impl Serializer { for line in &comment.content { self.writer.write_literal(prefix); - if !line - .as_ref() - .trim_matches(matches_fluent_ws) - .is_empty() - { + if !line.as_ref().trim_matches(matches_fluent_ws).is_empty() { self.writer.write_literal(" "); self.writer.write_literal(line.as_ref()); }