diff --git a/kclvm/tools/src/LSP/src/request.rs b/kclvm/tools/src/LSP/src/request.rs index 6adba1489..ad4b83717 100644 --- a/kclvm/tools/src/LSP/src/request.rs +++ b/kclvm/tools/src/LSP/src/request.rs @@ -386,13 +386,13 @@ pub(crate) fn handle_rename( params: lsp_types::RenameParams, sender: Sender, ) -> anyhow::Result> { - // // 1. check the new name validity + // 1. check the new name validity let new_name = params.new_name; if !is_valid_kcl_name(new_name.as_str()) { return Err(anyhow!("Can not rename to: {new_name}, invalid name")); } - // // 2. find all the references of the symbol + // 2. find all the references of the symbol let file = file_path_from_url(¶ms.text_document_position.text_document.uri)?; let path = from_lsp::abs_path(¶ms.text_document_position.text_document.uri)?; if !snapshot.verify_request_path(&path.clone().into(), &sender) { diff --git a/kclvm/tools/src/LSP/src/state.rs b/kclvm/tools/src/LSP/src/state.rs index ef011a027..c4acb13b2 100644 --- a/kclvm/tools/src/LSP/src/state.rs +++ b/kclvm/tools/src/LSP/src/state.rs @@ -140,13 +140,6 @@ impl LanguageServerState { request_retry: Arc::new(RwLock::new(HashMap::new())), }; - // // let word_index_map = state.word_index_map.clone(); - // state.thread_pool.execute(move || { - // if let Err(err) = update_word_index_state(word_index_map, initialize_params, true) { - // log_message(err.to_string(), &task_sender); - // } - // }); - state }