mirror of
https://github.com/zed-industries/zed.git
synced 2024-12-29 12:38:02 +00:00
When showing the next diagnostic, advance to the next *primary* one
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
This commit is contained in:
parent
0e51365770
commit
643545e91e
1 changed files with 1 additions and 0 deletions
|
@ -2209,6 +2209,7 @@ impl Editor {
|
|||
let buffer = self.buffer.read(cx.as_ref());
|
||||
let diagnostic_group_id = dbg!(buffer
|
||||
.diagnostics_in_range::<_, usize>(selection.head()..buffer.len())
|
||||
.filter(|(_, diagnostic)| diagnostic.is_primary)
|
||||
.next())
|
||||
.map(|(_, diagnostic)| diagnostic.group_id);
|
||||
|
||||
|
|
Loading…
Reference in a new issue