From 43cd0459b9ca383f18ca5b01b8c48e77737c3f1d Mon Sep 17 00:00:00 2001 From: David Sherret Date: Thu, 21 Oct 2021 10:18:18 -0400 Subject: fix(lsp): formatting should error on certain additional swc diagnostics (#12491) --- cli/proc_state.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'cli/proc_state.rs') diff --git a/cli/proc_state.rs b/cli/proc_state.rs index a633e3f9d..b7956d085 100644 --- a/cli/proc_state.rs +++ b/cli/proc_state.rs @@ -60,10 +60,10 @@ struct GraphData { // resolution map so that those errors can be surfaced at the appropriate time resolution_map: HashMap>, - // in some cases we want to provide the span where the resolution error + // in some cases we want to provide the range where the resolution error // occurred but need to surface it on load, but on load we don't know who the // referrer and span was, so we need to cache those - resolved_map: HashMap, + resolved_map: HashMap, // deno_graph detects all sorts of issues at build time (prepare_module_load) // but if they are errors at that stage, the don't cause the correct behaviors // so we cache the error and then surface it when appropriate (e.g. load) @@ -469,7 +469,7 @@ impl ProcState { Some(Err(err)) => { return Err(custom_error( "TypeError", - format!("{}\n", err.to_string_with_span()), + format!("{}\n", err.to_string_with_range()), )) } _ => (), -- cgit v1.2.3