aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src/application.rs
diff options
context:
space:
mode:
authorBlaž Hrastnik2021-09-03 02:40:49 +0000
committerBlaž Hrastnik2021-09-03 02:43:11 +0000
commit42f9718f55b58283253b2be85818a0aa0d5e3596 (patch)
tree06fedd0953079702890f45c89231fd8587705e99 /helix-term/src/application.rs
parent27c1b3f98b58edf690fda7caa2b14f34d6661598 (diff)
dap: Extract thread_picker, make pause explicitly select a thread
Diffstat (limited to 'helix-term/src/application.rs')
-rw-r--r--helix-term/src/application.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/helix-term/src/application.rs b/helix-term/src/application.rs
index eed7b914..527d374f 100644
--- a/helix-term/src/application.rs
+++ b/helix-term/src/application.rs
@@ -258,7 +258,7 @@ impl Application {
pub async fn handle_debugger_message(&mut self, payload: helix_dap::Payload) {
use crate::commands::dap::{resume_application, select_thread_id};
use helix_dap::{events, Event};
- let mut debugger = match self.editor.debugger.as_mut() {
+ let debugger = match self.editor.debugger.as_mut() {
Some(debugger) => debugger,
None => return,
};
@@ -274,12 +274,12 @@ impl Application {
..
}) => {
if let Some(thread_id) = thread_id {
- debugger.thread_states.insert(thread_id, reason); // TODO: dap uses "type" || "reason" here
+ debugger.thread_states.insert(thread_id, reason.clone()); // TODO: dap uses "type" || "reason" here
+
// whichever thread stops is made "current" (if no previously selected thread).
select_thread_id(&mut self.editor, thread_id, false).await;
}
-
let scope = match thread_id {
Some(id) => format!("Thread {}", id),
None => "Target".to_owned(),
@@ -305,7 +305,7 @@ impl Application {
}
}
Event::Thread(_) => {
- // TODO: update thread_states, make threads request
+ // TODO: update thread_states, make threads request
}
Event::Output(events::Output {
category, output, ..