on master help sign in
fix: move adapter_id out of DAP client
commit3d64cf8356044fb272fd0a93e8235f967b9da156 authorDmitry Sharshakov <d3dx12.xx@gmail.com> dateFri 13 Aug 2021, 20:18 (5 years ago) parentfabee03
2 files changed+3−3
helix-dap/examples/dap-basic.rs+1−1 helix-dap/src/client.rs+2−2
helix-dap/examples/dap-basic.rs+1−1
@@ -17,7 +17,7 @@ pub async fn main() -> Result<()> {
1717 println!("create: {:?}", client);
1818 let mut client = client?;
1919
20− println!("init: {:?}", client.initialize().await);
20+ println!("init: {:?}", client.initialize("go".to_owned()).await);
2121 println!("caps: {:#?}", client.capabilities());
2222 println!(
2323 "launch: {:?}",
helix-dap/src/client.rs+2−2
@@ -350,11 +350,11 @@ impl Client {
350350 .expect("language server not yet initialized!")
351351 }
352352
353− pub async fn initialize(&mut self) -> Result<()> {
353+ pub async fn initialize(&mut self, adapter_id: String) -> Result<()> {
354354 let args = InitializeArguments {
355355 client_id: "hx".to_owned(),
356356 client_name: "helix".to_owned(),
357− adapter_id: "go".to_owned(),
357+ adapter_id,
358358 locale: "en-us".to_owned(),
359359 lines_start_at_one: true,
360360 columns_start_at_one: true,