]> git.lizzy.rs Git - rust.git/commitdiff
One assist for function and method generation
authormahdi-frms <mahdif1380@outlook.com>
Sun, 8 Aug 2021 13:14:05 +0000 (17:44 +0430)
committermahdi-frms <mahdif1380@outlook.com>
Mon, 9 Aug 2021 16:36:24 +0000 (21:06 +0430)
crates/ide_assists/src/handlers/generate_function.rs

index 426f20cd15b9b35219ff35303a707f60ae98c613..50d3a74f2768cbd0b29e5664b175be19589936d9 100644 (file)
@@ -131,8 +131,8 @@ pub(crate) fn generate_method(acc: &mut Assists, ctx: &AssistContext) -> Option<
     let target = call.syntax().text_range();
 
     acc.add(
-        AssistId("generate_method", AssistKind::Generate),
-        format!("Generate `{}` method", function_builder.fn_name),
+        AssistId("generate_function", AssistKind::Generate),
+        format!("Generate `{}` function", function_builder.fn_name),
         target,
         |builder| {
             let function_template = function_builder.render();