mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-25 04:23:25 +00:00
Let shutdown request to pass through when status == Loading
This commit is contained in:
parent
e43811c164
commit
dbe7ede2ee
1 changed files with 1 additions and 1 deletions
|
@ -337,7 +337,7 @@ impl GlobalState {
|
||||||
fn on_request(&mut self, request_received: Instant, req: Request) -> Result<()> {
|
fn on_request(&mut self, request_received: Instant, req: Request) -> Result<()> {
|
||||||
self.register_request(&req, request_received);
|
self.register_request(&req, request_received);
|
||||||
|
|
||||||
if self.status == Status::Loading {
|
if self.status == Status::Loading && req.method != "shutdown" {
|
||||||
self.respond(lsp_server::Response::new_err(
|
self.respond(lsp_server::Response::new_err(
|
||||||
req.id,
|
req.id,
|
||||||
// FIXME: i32 should impl From<ErrorCode> (from() guarantees lossless conversion)
|
// FIXME: i32 should impl From<ErrorCode> (from() guarantees lossless conversion)
|
||||||
|
|
Loading…
Reference in a new issue