Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/syntax/src/ast/traits.rs')
| -rw-r--r-- | crates/syntax/src/ast/traits.rs | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/crates/syntax/src/ast/traits.rs b/crates/syntax/src/ast/traits.rs index 5d6aa4331b..5290f32dd2 100644 --- a/crates/syntax/src/ast/traits.rs +++ b/crates/syntax/src/ast/traits.rs @@ -4,9 +4,9 @@ use either::Either; use crate::{ - ast::{self, support, AstChildren, AstNode, AstToken}, - syntax_node::SyntaxElementChildren, SyntaxElement, SyntaxToken, T, + ast::{self, AstChildren, AstNode, AstToken, support}, + syntax_node::SyntaxElementChildren, }; pub trait HasName: AstNode { @@ -121,11 +121,7 @@ impl DocCommentIter { &mut self.filter_map(|comment| comment.doc_comment().map(ToOwned::to_owned)), "\n", ); - if docs.is_empty() { - None - } else { - Some(docs) - } + if docs.is_empty() { None } else { Some(docs) } } } |