diff options
author | Dmitry Sharshakov | 2021-08-14 08:13:02 +0000 |
---|---|---|
committer | Blaž Hrastnik | 2021-08-20 04:43:54 +0000 |
commit | c5492788a23056dd82874a8524226dc20e2becc8 (patch) | |
tree | 2d7f6ee39607b004e155ca04cd57a851e26290e5 | |
parent | cc650c7f4f7e63d9417ceb3a0f302a575297dd98 (diff) |
compat: remove seq from Response and Event
-rw-r--r-- | helix-dap/src/transport.rs | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/helix-dap/src/transport.rs b/helix-dap/src/transport.rs index 37aa9e25..cb16e45e 100644 --- a/helix-dap/src/transport.rs +++ b/helix-dap/src/transport.rs @@ -26,7 +26,7 @@ pub struct Request { #[derive(Debug, PartialEq, Clone, Deserialize, Serialize)] pub struct Response { - pub seq: u64, + // seq is omitted as unused and is not sent by some implementations #[serde(rename = "type")] pub msg_type: String, pub request_seq: u64, @@ -38,7 +38,7 @@ pub struct Response { #[derive(Debug, PartialEq, Clone, Deserialize, Serialize)] pub struct Event { - pub seq: u64, + // seq is omitted as unused and is not sent by some implementations #[serde(rename = "type")] pub msg_type: String, pub event: String, @@ -165,10 +165,7 @@ impl Transport { fn process_response(res: Response) -> Result<Response> { match res.success { true => { - info!( - "<- DAP success ({}, in response to {})", - res.seq, res.request_seq - ); + info!("<- DAP success in response to {}", res.request_seq); Ok(res) } @@ -218,10 +215,8 @@ impl Transport { client_tx.send(msg).expect("Failed to send"); Ok(()) } - Payload::Event(Event { - ref event, ref seq, .. - }) => { - info!("<- DAP event {} #{}", event, seq); + Payload::Event(Event { ref event, .. }) => { + info!("<- DAP event {}", event); client_tx.send(msg).expect("Failed to send"); Ok(()) } |