]> git.lizzy.rs Git - rust.git/commitdiff
fmt
authorJeroen Vannevel <jer_vannevel@outlook.com>
Fri, 7 Jan 2022 12:40:41 +0000 (12:40 +0000)
committerJeroen Vannevel <jer_vannevel@outlook.com>
Fri, 7 Jan 2022 12:40:41 +0000 (12:40 +0000)
crates/ide_assists/src/handlers/add_turbo_fish.rs

index e493e4e192e9dafc29c02205e66a519d21f53c63..f67c65d16684d884b4b2aa34b51f2d8a3b8e62f2 100644 (file)
@@ -79,7 +79,9 @@ pub(crate) fn add_turbo_fish(acc: &mut Assists, ctx: &AssistContext) -> Option<(
 
     let number_of_arguments = generics
         .iter()
-        .filter(|param| matches!(param, hir::GenericParam::TypeParam(_) | hir::GenericParam::ConstParam(_)))
+        .filter(|param| {
+            matches!(param, hir::GenericParam::TypeParam(_) | hir::GenericParam::ConstParam(_))
+        })
         .count();
     let fish_head = std::iter::repeat("_").take(number_of_arguments).collect::<Vec<_>>().join(",");