mirror of
https://github.com/zed-industries/zed.git
synced 2025-01-24 11:01:54 +00:00
9999c31859
Follow-up of https://github.com/zed-industries/zed/pull/21173 Rust-analyzer with `checkOnSave` enabled will push diagnostics for a file after each diagnostics refresh (e.g. save, file open, file close). If there's a file that is not open in any pane and has only warnings, and the diagnostics editor has warnings toggled off, then 0. rust-analyzer will push the corresponding warnings after initial load 1. the diagnostics editor code registers `project::Event::DiagnosticsUpdated` for the corresponding file path and opens the corresponding buffer to read its associated diagnostics from the snapshot 2. opening the buffer would send `textDocument/didOpen` which would trigger rust-analyzer to push the same diagnostics 3. meanwhile, the diagnostics editor would filter out all diagnostics for that buffer, dropping the open buffer and effectively closing it 4. closing the buffer will send `textDocument/didClose` which would trigger rust-analyzer to push the same diagnostics again, as those are `cargo check` ones, still present in the file 5. GOTO 1 Release Notes: - Fixed diagnostics editor not scrolling properly under certain conditions |
||
---|---|---|
.. | ||
src | ||
Cargo.toml | ||
LICENSE-GPL |