diff --git a/helix-term/src/commands/lsp.rs b/helix-term/src/commands/lsp.rs index ac9dd6e27..a85aef7f6 100644 --- a/helix-term/src/commands/lsp.rs +++ b/helix-term/src/commands/lsp.rs @@ -231,6 +231,13 @@ fn diag_picker( } } + flat_diag.sort_by(|a, b| { + a.diag + .severity + .unwrap_or(lsp::DiagnosticSeverity::HINT) + .cmp(&b.diag.severity.unwrap_or(lsp::DiagnosticSeverity::HINT)) + }); + let styles = DiagnosticStyles { hint: cx.editor.theme.get("hint"), info: cx.editor.theme.get("info"),