fix: move adapter_id out of DAP client

pull/574/head
Dmitry Sharshakov 3 years ago committed by Blaž Hrastnik
parent fabee03983
commit 3d64cf8356

@ -17,7 +17,7 @@ pub async fn main() -> Result<()> {
println!("create: {:?}", client); println!("create: {:?}", client);
let mut client = client?; let mut client = client?;
println!("init: {:?}", client.initialize().await); println!("init: {:?}", client.initialize("go".to_owned()).await);
println!("caps: {:#?}", client.capabilities()); println!("caps: {:#?}", client.capabilities());
println!( println!(
"launch: {:?}", "launch: {:?}",

@ -350,11 +350,11 @@ impl Client {
.expect("language server not yet initialized!") .expect("language server not yet initialized!")
} }
pub async fn initialize(&mut self) -> Result<()> { pub async fn initialize(&mut self, adapter_id: String) -> Result<()> {
let args = InitializeArguments { let args = InitializeArguments {
client_id: "hx".to_owned(), client_id: "hx".to_owned(),
client_name: "helix".to_owned(), client_name: "helix".to_owned(),
adapter_id: "go".to_owned(), adapter_id,
locale: "en-us".to_owned(), locale: "en-us".to_owned(),
lines_start_at_one: true, lines_start_at_one: true,
columns_start_at_one: true, columns_start_at_one: true,

Loading…
Cancel
Save