@@ -163,7 +163,7 @@ pub fn dap_start_impl(
163 let (_, doc) = current!(editor);
163 let (_, doc) = current!(editor);
165 let path = match doc.path() {
165 let path = match doc.path() {
166− Some(path) => path.to_path_buf(),
166+ Some(path) => path,
167 None => {
167 None => {
168 editor.set_error("Can't start debug: document has no path".to_string());
168 editor.set_error("Can't start debug: document has no path".to_string());
@@ -420,7 +420,7 @@ pub fn dap_toggle_breakpoint(cx: &mut Context) {
422 let path = match doc.path() {
422 let path = match doc.path() {
423− Some(path) => path.to_path_buf(),
423+ Some(path) => path,
424 None => {
424 None => {
425 cx.editor
425 cx.editor
426 .set_error("Can't set breakpoint: document has no path".to_string());
426 .set_error("Can't set breakpoint: document has no path".to_string());
@@ -444,7 +444,7 @@ pub fn dap_toggle_breakpoint(cx: &mut Context) {
444 Some(debugger) => debugger,
444 Some(debugger) => debugger,
445 None => return,
445 None => return,
447− let request = debugger.set_breakpoints(path, breakpoints);
447+ let request = debugger.set_breakpoints(path.clone(), breakpoints);
448 match block_on(request) {
448 match block_on(request) {
449 Ok(Some(breakpoints)) => {
449 Ok(Some(breakpoints)) => {
450 let old_breakpoints = debugger.breakpoints.clone();
450 let old_breakpoints = debugger.breakpoints.clone();
@@ -671,7 +671,7 @@ pub fn dap_edit_condition(cx: &mut Context) {
672 let (_, doc) = current!(cx.editor);
672 let (_, doc) = current!(cx.editor);
673 let path = match doc.path() {
673 let path = match doc.path() {
674− Some(path) => path.to_path_buf(),
674+ Some(path) => path,
675 None => {
675 None => {
676 cx.editor.set_status(
676 cx.editor.set_status(
677 "Can't edit breakpoint: document has no path".to_owned(),
677 "Can't edit breakpoint: document has no path".to_owned(),
@@ -713,7 +713,8 @@ pub fn dap_edit_condition(cx: &mut Context) {
714 // bail!("Can't edit breakpoint: debugger does not support logpoints")
714 // bail!("Can't edit breakpoint: debugger does not support logpoints")
716− let request = debugger.set_breakpoints(path, breakpoints.clone());
717+ debugger.set_breakpoints(path.clone(), breakpoints.clone());
717 if let Err(e) = block_on(request) {
718 if let Err(e) = block_on(request) {
718 cx.editor
719 cx.editor
719 .set_status(format!("Failed to set breakpoints: {:?}", e))
720 .set_status(format!("Failed to set breakpoints: {:?}", e))
@@ -749,7 +750,7 @@ pub fn dap_edit_log(cx: &mut Context) {
750 let (_, doc) = current!(cx.editor);
751 let (_, doc) = current!(cx.editor);
751 let path = match doc.path() {
752 let path = match doc.path() {
752− Some(path) => path.to_path_buf(),
753+ Some(path) => path,
753 None => {
754 None => {
754 cx.editor.set_status(
755 cx.editor.set_status(
755 "Can't edit breakpoint: document has no path".to_owned(),
756 "Can't edit breakpoint: document has no path".to_owned(),
@@ -791,7 +792,8 @@ pub fn dap_edit_log(cx: &mut Context) {
792 // bail!("Can't edit breakpoint: debugger does not support logpoints")
793 // bail!("Can't edit breakpoint: debugger does not support logpoints")
794− let request = debugger.set_breakpoints(path, breakpoints.clone());
796+ debugger.set_breakpoints(path.clone(), breakpoints.clone());
795 if let Err(e) = block_on(request) {
797 if let Err(e) = block_on(request) {
796 cx.editor
798 cx.editor
797 .set_status(format!("Failed to set breakpoints: {:?}", e))
799 .set_status(format!("Failed to set breakpoints: {:?}", e))