File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -372,8 +372,6 @@ impl GlobalState {
372372 // handlers that mutate those still refresh explicitly.
373373 let old_revision = salsa:: plumbing:: current_revision ( & self . world . db ) ;
374374
375- lsp:: log_info!( "Processing next event" ) ;
376-
377375 match event {
378376 Event :: Lsp ( msg) => match msg {
379377 LspMessage :: Notification ( notif) => {
@@ -993,17 +991,14 @@ static DIAGNOSTICS_QUEUE: LazyLock<tokio::sync::mpsc::UnboundedSender<RefreshDia
993991/// newer one and publish last, leaving diagnostics computed from the older
994992/// console scopes or config until the next refresh.
995993async fn process_diagnostics_queue ( mut rx : mpsc:: UnboundedReceiver < RefreshDiagnosticsTask > ) {
996- loop {
997- let Some ( task) = rx. recv ( ) . await else {
998- lsp:: log_warn!( "process_diagnostics_queue: channel closed, task exiting" ) ;
999- return ;
1000- } ;
994+ while let Some ( task) = rx. recv ( ) . await {
1001995 let mut batch = vec ! [ task] ;
1002996 while let Ok ( task) = rx. try_recv ( ) {
1003997 batch. push ( task) ;
1004998 }
1005999 process_diagnostics_batch ( batch) ;
10061000 }
1001+ lsp:: log_warn!( "process_diagnostics_queue: channel closed, task exiting" ) ;
10071002}
10081003
10091004fn process_diagnostics_batch ( batch : Vec < RefreshDiagnosticsTask > ) {
You can’t perform that action at this time.
0 commit comments