diff --git a/crates/plugin_macros/Cargo.toml b/crates/plugin_macros/Cargo.toml index 1ba3c64831..1fa21a8fff 100644 --- a/crates/plugin_macros/Cargo.toml +++ b/crates/plugin_macros/Cargo.toml @@ -7,7 +7,6 @@ edition = "2021" proc-macro = true [dependencies] -# TODO: remove "extra-traits" syn = { version = "1.0", features = ["full", "extra-traits"] } quote = "1.0" proc-macro2 = "1.0" diff --git a/crates/project/src/project.rs b/crates/project/src/project.rs index 3defd81573..8095ceeab7 100644 --- a/crates/project/src/project.rs +++ b/crates/project/src/project.rs @@ -1722,7 +1722,7 @@ impl Project { .await?; this.update(&mut cx, |this, cx| { this.assign_language_to_buffer(&buffer, cx); - this.register_buffer_with_language_server(&buffer, cx) + this.register_buffer_with_language_server(&buffer, cx); }); Ok(()) }) @@ -2120,6 +2120,14 @@ impl Project { let adapter = adapter.clone(); move |params, mut cx| { if let Some(this) = this.upgrade(&cx) { + // cx.spawn(|cx| { + // this.update(&mut cx, |this, cx| { + // this.on_lsp_diagnostics_published( + // server_id, params, adapter, cx, + // ) + // }) + // }) + // .detach(); this.update(&mut cx, |this, cx| { // TODO(isaac): remove block on smol::block_on(this.on_lsp_diagnostics_published( @@ -3414,11 +3422,11 @@ impl Project { } new_symbols }); - for new_symbol in new_symbols { - if let Some(new_symbol) = new_symbol.await.ok() { - symbols.push(new_symbol); - } - } + symbols = futures::future::join_all(new_symbols.into_iter()) + .await + .into_iter() + .filter_map(|symbol| symbol.ok()) + .collect::>(); } Ok(symbols) }) diff --git a/crates/zed/src/main.rs b/crates/zed/src/main.rs index be81944e08..36dac1aa40 100644 --- a/crates/zed/src/main.rs +++ b/crates/zed/src/main.rs @@ -225,10 +225,10 @@ fn main() { cx.spawn({ let languages = languages.clone(); |cx| async move { - // init_languages.await; cx.read(|cx| { languages.set_theme(cx.global::().theme.editor.syntax.clone()) }); + init_languages.await; } }) .detach();