From 87e3cd3df283a6da055488bbea60637713bd1f35 Mon Sep 17 00:00:00 2001 From: Blaž Hrastnik Date: Mon, 15 Mar 2021 16:19:31 +0900 Subject: ui: Render diagnostic errors in sideline. --- helix-term/src/application.rs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'helix-term/src/application.rs') diff --git a/helix-term/src/application.rs b/helix-term/src/application.rs index 24b5317b..c22cf996 100644 --- a/helix-term/src/application.rs +++ b/helix-term/src/application.rs @@ -140,14 +140,17 @@ impl Application { .into_iter() .map(|diagnostic| { use helix_core::diagnostic::Severity::*; - use helix_core::{diagnostic::Severity, Diagnostic}; + use helix_core::{ + diagnostic::{Range, Severity}, + Diagnostic, + }; use helix_lsp::{lsp, util::lsp_pos_to_pos}; use lsp::DiagnosticSeverity; let start = lsp_pos_to_pos(doc, diagnostic.range.start); let end = lsp_pos_to_pos(doc, diagnostic.range.end); Diagnostic { - range: (start, end), + range: Range { start, end }, line: diagnostic.range.start.line as usize, message: diagnostic.message, severity: diagnostic.severity.map( -- cgit v1.2.3-70-g09d2