diff options
author | Emil Lauridsen <[email protected]> | 2019-12-29 18:14:18 +0000 |
---|---|---|
committer | Emil Lauridsen <[email protected]> | 2019-12-29 18:14:18 +0000 |
commit | 96156b95b52380fe7456cf9a163cb3de8ea6907f (patch) | |
tree | 84b5f08a378b58e120dc19e80598781e8520c929 /crates/ra_cargo_watch | |
parent | b30de4ed49be362ed8fd71ac367c90554441b079 (diff) |
Resolve macro call site in more cases
Diffstat (limited to 'crates/ra_cargo_watch')
-rw-r--r-- | crates/ra_cargo_watch/src/conv.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_cargo_watch/src/conv.rs b/crates/ra_cargo_watch/src/conv.rs index 3bd4bf7a5..eedfea02b 100644 --- a/crates/ra_cargo_watch/src/conv.rs +++ b/crates/ra_cargo_watch/src/conv.rs | |||
@@ -48,7 +48,7 @@ fn map_macro_span_to_location( | |||
48 | 48 | ||
49 | /// Converts a Rust span to a LSP location | 49 | /// Converts a Rust span to a LSP location |
50 | fn map_span_to_location(span: &DiagnosticSpan, workspace_root: &PathBuf) -> Location { | 50 | fn map_span_to_location(span: &DiagnosticSpan, workspace_root: &PathBuf) -> Location { |
51 | if is_from_macro(&span.file_name) && span.expansion.is_some() { | 51 | if span.expansion.is_some() { |
52 | let expansion = span.expansion.as_ref().unwrap(); | 52 | let expansion = span.expansion.as_ref().unwrap(); |
53 | if let Some(macro_range) = map_macro_span_to_location(&expansion, workspace_root) { | 53 | if let Some(macro_range) = map_macro_span_to_location(&expansion, workspace_root) { |
54 | return macro_range; | 54 | return macro_range; |