From 0ed27c388adca887cda3d8141efaf974e90a5958 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Thu, 9 Apr 2020 23:02:10 +0200 Subject: Drop needless trait --- crates/ra_syntax/src/ast/traits.rs | 6 ------ 1 file changed, 6 deletions(-) (limited to 'crates/ra_syntax/src/ast/traits.rs') diff --git a/crates/ra_syntax/src/ast/traits.rs b/crates/ra_syntax/src/ast/traits.rs index f6c786e44..f0b54cf29 100644 --- a/crates/ra_syntax/src/ast/traits.rs +++ b/crates/ra_syntax/src/ast/traits.rs @@ -43,12 +43,6 @@ pub trait ArgListOwner: AstNode { } } -pub trait FnDefOwner: AstNode { - fn functions(&self) -> AstChildren { - support::children(self.syntax()) - } -} - pub trait ModuleItemOwner: AstNode { fn items(&self) -> AstChildren { support::children(self.syntax()) -- cgit v1.2.3 From 046a02101355bb58cf66218f7dd6dc4fa78fc53f Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Thu, 9 Apr 2020 23:05:13 +0200 Subject: use stdx --- crates/ra_syntax/src/ast/traits.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'crates/ra_syntax/src/ast/traits.rs') diff --git a/crates/ra_syntax/src/ast/traits.rs b/crates/ra_syntax/src/ast/traits.rs index f0b54cf29..4ed7cf73b 100644 --- a/crates/ra_syntax/src/ast/traits.rs +++ b/crates/ra_syntax/src/ast/traits.rs @@ -1,8 +1,7 @@ //! Various traits that are implemented by ast nodes. //! //! The implementations are usually trivial, and live in generated.rs - -use itertools::Itertools; +use stdx::SepBy; use crate::{ ast::{self, support, AstChildren, AstNode, AstToken}, @@ -116,7 +115,8 @@ pub trait DocCommentsOwner: AstNode { // of a line in markdown. line[pos..end].to_owned() }) - .join("\n"); + .sep_by("\n") + .to_string(); if has_comments { Some(docs) -- cgit v1.2.3