From 41632fac8619e277f886aaa901e65726ecba7e5f Mon Sep 17 00:00:00 2001 From: cui fliter Date: Mon, 1 May 2023 14:53:25 +0800 Subject: [PATCH] fix some typos Signed-off-by: cui fliter --- crates/ide-assists/src/handlers/add_return_type.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/crates/ide-assists/src/handlers/add_return_type.rs b/crates/ide-assists/src/handlers/add_return_type.rs index 9e1022d809d..e5f0201bd52 100644 --- a/crates/ide-assists/src/handlers/add_return_type.rs +++ b/crates/ide-assists/src/handlers/add_return_type.rs @@ -34,8 +34,8 @@ pub(crate) fn add_return_type(acc: &mut Assists, ctx: &AssistContext<'_>) -> Opt |builder| { match builder_edit_pos { InsertOrReplace::Insert(insert_pos, needs_whitespace) => { - let preceeding_whitespace = if needs_whitespace { " " } else { "" }; - builder.insert(insert_pos, format!("{preceeding_whitespace}-> {ty} ")) + let preceding_whitespace = if needs_whitespace { " " } else { "" }; + builder.insert(insert_pos, format!("{preceding_whitespace}-> {ty} ")) } InsertOrReplace::Replace(text_range) => { builder.replace(text_range, format!("-> {ty}"))