diff options
author | Kitson Kelly <me@kitsonkelly.com> | 2021-05-12 13:10:06 +1000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-12 13:10:06 +1000 |
commit | 0e17f086ce3795dc958e2bb8dad2bf3525d2b55f (patch) | |
tree | dbd61d6462d90c144f9666b061dc67a69e82a572 /cli/bench/lsp.rs | |
parent | 57927781ed7eb8bb088d656768dc295716407c7a (diff) |
fix(#10603): revert minimal changes to resolve deadlock bug (#10605)
Diffstat (limited to 'cli/bench/lsp.rs')
-rw-r--r-- | cli/bench/lsp.rs | 36 |
1 files changed, 20 insertions, 16 deletions
diff --git a/cli/bench/lsp.rs b/cli/bench/lsp.rs index 173c52774..ed474b9ea 100644 --- a/cli/bench/lsp.rs +++ b/cli/bench/lsp.rs @@ -184,6 +184,7 @@ impl LspClient { } } + #[allow(unused)] fn read_request<R>(&mut self) -> Result<(u64, String, Option<R>), AnyError> where R: de::DeserializeOwned, @@ -238,6 +239,7 @@ impl LspClient { } } + #[allow(unused)] fn write_response<V>(&mut self, id: u64, result: V) -> Result<(), AnyError> where V: Serialize, @@ -294,15 +296,16 @@ fn bench_big_file_edits(deno_exe: &Path) -> Result<Duration, AnyError> { }), )?; - let (id, method, _): (u64, String, Option<Value>) = client.read_request()?; - assert_eq!(method, "workspace/configuration"); + // TODO(@kitsonk) work around https://github.com/denoland/deno/issues/10603 + // let (id, method, _): (u64, String, Option<Value>) = client.read_request()?; + // assert_eq!(method, "workspace/configuration"); - client.write_response( - id, - json!({ - "enable": true - }), - )?; + // client.write_response( + // id, + // json!({ + // "enable": true + // }), + // )?; let (method, _): (String, Option<Value>) = client.read_notification()?; assert_eq!(method, "textDocument/publishDiagnostics"); @@ -366,15 +369,16 @@ fn bench_startup_shutdown(deno_exe: &Path) -> Result<Duration, AnyError> { }), )?; - let (id, method, _): (u64, String, Option<Value>) = client.read_request()?; - assert_eq!(method, "workspace/configuration"); + // TODO(@kitsonk) work around https://github.com/denoland/deno/issues/10603 + // let (id, method, _): (u64, String, Option<Value>) = client.read_request()?; + // assert_eq!(method, "workspace/configuration"); - client.write_response( - id, - json!({ - "enable": true - }), - )?; + // client.write_response( + // id, + // json!({ + // "enable": true + // }), + // )?; let (method, _): (String, Option<Value>) = client.read_notification()?; assert_eq!(method, "textDocument/publishDiagnostics"); |