From 54dc2f8107229952928bc68f24946398a84cd56b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bla=C5=BE=20Hrastnik?= Date: Mon, 16 Aug 2021 14:05:10 +0900 Subject: [PATCH] Fix example compilation --- helix-dap/examples/dap-dlv.rs | 4 ++-- helix-dap/examples/dap-lldb.rs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/helix-dap/examples/dap-dlv.rs b/helix-dap/examples/dap-dlv.rs index 352c21444..bffca6766 100644 --- a/helix-dap/examples/dap-dlv.rs +++ b/helix-dap/examples/dap-dlv.rs @@ -1,6 +1,6 @@ use helix_dap::{events, Client, Event, Result, SourceBreakpoint}; use serde::{Deserialize, Serialize}; -use serde_json::from_value; +use serde_json::{from_value, to_value}; use tokio::sync::mpsc::Receiver; #[derive(Debug, PartialEq, Clone, Deserialize, Serialize)] @@ -50,7 +50,7 @@ pub async fn main() -> Result<()> { program: "/tmp/godebug/main".to_owned(), }; - println!("launch: {:?}", client.launch(args).await); + println!("launch: {:?}", client.launch(to_value(args)?).await); println!( "breakpoints: {:#?}", diff --git a/helix-dap/examples/dap-lldb.rs b/helix-dap/examples/dap-lldb.rs index 85ff27625..c9a99548a 100644 --- a/helix-dap/examples/dap-lldb.rs +++ b/helix-dap/examples/dap-lldb.rs @@ -1,6 +1,6 @@ use helix_dap::{events, Client, Event, Result, SourceBreakpoint}; use serde::{Deserialize, Serialize}; -use serde_json::from_value; +use serde_json::{from_value, to_value}; use tokio::sync::mpsc::Receiver; #[derive(Debug, PartialEq, Clone, Deserialize, Serialize)] @@ -50,7 +50,7 @@ pub async fn main() -> Result<()> { console: "internalConsole".to_owned(), }; - println!("launch: {:?}", client.launch(args).await); + println!("launch: {:?}", client.launch(to_value(args)?).await); println!( "breakpoints: {:#?}",