Skip to content

Commit a804ccd

Browse files
ndmitchellfacebook-github-bot
authored andcommitted
Delete the context object from the DAP server
Summary: Newer clippy managed to spot the field was dead. We didn't use it, and it's not clear we ever would. Reviewed By: stepancheg Differential Revision: D31616030 fbshipit-source-id: 768fa81cde7a25b5997f9ade3ba908b76ac74919
1 parent f8ad1b6 commit a804ccd

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

starlark/bin/dap/mod.rs

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,13 @@ use starlark::{
3737
syntax::{AstModule, Dialect},
3838
};
3939

40-
use crate::eval::{dialect, globals, Context};
40+
use crate::eval::{dialect, globals};
4141

4242
mod library;
4343

4444
#[derive(Debug)]
4545
struct Backend {
4646
client: Client,
47-
starlark: Context,
48-
4947
file: Mutex<Option<String>>,
5048

5149
// These breakpoints must all match statements as per before_stmt.
@@ -380,11 +378,10 @@ impl DebugServer for Backend {
380378
}
381379
}
382380

383-
pub fn server(starlark: Context) {
381+
pub fn server() {
384382
let (sender, receiver) = channel();
385383
DapService::run(|client| Backend {
386384
client,
387-
starlark,
388385
breakpoints: Default::default(),
389386
disable_breakpoints: Default::default(),
390387
file: Default::default(),

starlark/bin/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ fn main() -> anyhow::Result<()> {
239239
ctx.run = false;
240240
lsp::server(ctx)?;
241241
} else if args.dap {
242-
dap::server(ctx)
242+
dap::server()
243243
}
244244

245245
if !args.json {

0 commit comments

Comments
 (0)