diff options
author | kjeremy <[email protected]> | 2020-10-21 19:57:55 +0100 |
---|---|---|
committer | kjeremy <[email protected]> | 2020-10-26 13:23:34 +0000 |
commit | 5cb6fafd366158ac5d9461819dbb0fb7018ad685 (patch) | |
tree | 4cced8415251921c09efe4fec71a36a2c9da0aa2 /crates/rust-analyzer/src/diagnostics | |
parent | 35ed3d2c005fdb0ec9ab78a52b31758bd7de298e (diff) |
Latest proposed LSP 3.16.0
Needs: https://github.com/gluon-lang/lsp-types/pull/183
Diffstat (limited to 'crates/rust-analyzer/src/diagnostics')
-rw-r--r-- | crates/rust-analyzer/src/diagnostics/to_proto.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/crates/rust-analyzer/src/diagnostics/to_proto.rs b/crates/rust-analyzer/src/diagnostics/to_proto.rs index 33606edda..b949577c1 100644 --- a/crates/rust-analyzer/src/diagnostics/to_proto.rs +++ b/crates/rust-analyzer/src/diagnostics/to_proto.rs | |||
@@ -248,10 +248,12 @@ pub(crate) fn map_rust_diagnostic_to_lsp( | |||
248 | range: in_macro_location.range, | 248 | range: in_macro_location.range, |
249 | severity, | 249 | severity, |
250 | code: code.clone().map(lsp_types::NumberOrString::String), | 250 | code: code.clone().map(lsp_types::NumberOrString::String), |
251 | code_description: None, | ||
251 | source: Some(source.clone()), | 252 | source: Some(source.clone()), |
252 | message: message.clone(), | 253 | message: message.clone(), |
253 | related_information: Some(information_for_additional_diagnostic), | 254 | related_information: Some(information_for_additional_diagnostic), |
254 | tags: if tags.is_empty() { None } else { Some(tags.clone()) }, | 255 | tags: if tags.is_empty() { None } else { Some(tags.clone()) }, |
256 | data: None, | ||
255 | }; | 257 | }; |
256 | 258 | ||
257 | Some(MappedRustDiagnostic { | 259 | Some(MappedRustDiagnostic { |
@@ -267,6 +269,7 @@ pub(crate) fn map_rust_diagnostic_to_lsp( | |||
267 | range: location.range, | 269 | range: location.range, |
268 | severity, | 270 | severity, |
269 | code: code.clone().map(lsp_types::NumberOrString::String), | 271 | code: code.clone().map(lsp_types::NumberOrString::String), |
272 | code_description: None, | ||
270 | source: Some(source.clone()), | 273 | source: Some(source.clone()), |
271 | message, | 274 | message, |
272 | related_information: if related_information.is_empty() { | 275 | related_information: if related_information.is_empty() { |
@@ -275,6 +278,7 @@ pub(crate) fn map_rust_diagnostic_to_lsp( | |||
275 | Some(related_information.clone()) | 278 | Some(related_information.clone()) |
276 | }, | 279 | }, |
277 | tags: if tags.is_empty() { None } else { Some(tags.clone()) }, | 280 | tags: if tags.is_empty() { None } else { Some(tags.clone()) }, |
281 | data: None, | ||
278 | }; | 282 | }; |
279 | 283 | ||
280 | let main_diagnostic = | 284 | let main_diagnostic = |