From ba72308588e50b7e8a514b7b83946e5ec3cf2e96 Mon Sep 17 00:00:00 2001 From: Aleksey Kladov Date: Fri, 19 Mar 2021 21:00:20 +0300 Subject: simplify changelog skip --- crates/ide_assists/src/handlers/move_bounds.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/crates/ide_assists/src/handlers/move_bounds.rs b/crates/ide_assists/src/handlers/move_bounds.rs index 9ad0c9816..b5dec8014 100644 --- a/crates/ide_assists/src/handlers/move_bounds.rs +++ b/crates/ide_assists/src/handlers/move_bounds.rs @@ -50,8 +50,8 @@ pub(crate) fn move_bounds_to_where_clause(acc: &mut Assists, ctx: &AssistContext for type_param in type_param_list.type_params() { if let Some(tbl) = type_param.type_bound_list() { - if let Some(predicate) = build_predicate(type_param.clone()) { - where_clause.add_predicate(predicate.clone_for_update()) + if let Some(predicate) = build_predicate(type_param) { + where_clause.add_predicate(predicate) } tbl.remove() } @@ -69,7 +69,7 @@ fn build_predicate(param: ast::TypeParam) -> Option { make::path_unqualified(segment) }; let predicate = make::where_pred(path, param.type_bound_list()?.bounds()); - Some(predicate) + Some(predicate.clone_for_update()) } #[cfg(test)] -- cgit v1.2.3