-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Jump to next/prev diagnostic in workspace (#3116) #4201
base: master
Are you sure you want to change the base?
Jump to next/prev diagnostic in workspace (#3116) #4201
Conversation
I think Changing diagnostics to |
The space menu has |
Yeah I agree, ideally the same letter for everything would be better. I wonder if the correct thing would be to replace the Having |
Edit: Ah I didn't see that there were four workspace diagnostic keybind variants. In that case we could bind to |
New user here - the |
Implements functions and keybindings to move to next/previous/first/last diagnostic in the workspace
262ab16
to
83d4110
Compare
That's would be awesome if it will jump to errors first and then to warnings and so on |
What's the current blocker for this? I can help finish the work if needed. Maybe we can provide only the commands for now, so users can bind them to whatever they want until we find a good default. When making a change in a Rust codebase, I often just let the compiler guide me to see what other places are affected by my change. If I could jump from diagnostic to diagnostic across files, without opening the workspace diagnostic picker each time, it will be awesome. |
Not sure, I think it's just a matter of no one having the time to review this since it's probably near the bottom of priorities. |
Implements functions and keybindings to move to next/previous/first/last diagnostic in the workspace as per #3116
I've also refactored some functions a little bit to reduce code duplication.
It's not entirely clear to me what's the clear cut between a function being in
commands.rs
or incommands/lsp.rs
. I tried following the current code, but let me know if I have to move something.There's some code repetition going on in
get_next_diag_doc
. I tried finding ways to handle the fact that the direction branches produce anIter
and aRev
, but the only solutions I found were based on external libraries not currenlty used (itertools, either).Please, feel free to correct anything wrong here and suggest better practices.