aboutsummaryrefslogtreecommitdiff
path: root/helix-lsp
diff options
context:
space:
mode:
Diffstat (limited to 'helix-lsp')
-rw-r--r--helix-lsp/Cargo.toml2
-rw-r--r--helix-lsp/src/lib.rs4
2 files changed, 5 insertions, 1 deletions
diff --git a/helix-lsp/Cargo.toml b/helix-lsp/Cargo.toml
index 2c1b813d..80025698 100644
--- a/helix-lsp/Cargo.toml
+++ b/helix-lsp/Cargo.toml
@@ -23,5 +23,5 @@ lsp-types = { version = "0.89", features = ["proposed"] }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
thiserror = "1.0"
-tokio = { version = "1.6", features = ["full"] }
+tokio = { version = "1.7", features = ["full"] }
tokio-stream = "0.1.6"
diff --git a/helix-lsp/src/lib.rs b/helix-lsp/src/lib.rs
index 49d5527f..b25a7aca 100644
--- a/helix-lsp/src/lib.rs
+++ b/helix-lsp/src/lib.rs
@@ -347,6 +347,10 @@ impl LspProgressMap {
self.0.get(&id)
}
+ pub fn is_progressing(&self, id: usize) -> bool {
+ self.0.get(&id).map(|it| !it.is_empty()).unwrap_or_default()
+ }
+
/// Returns last progress status for a given server with `id` and `token`.
pub fn progress(&self, id: usize, token: &lsp::ProgressToken) -> Option<&ProgressStatus> {
self.0.get(&id).and_then(|values| values.get(token))