Add experimental VSCode api
This commit is contained in:
committed by
Laurențiu Nicola
parent
9d473a0b9f
commit
55371be807
@@ -412,13 +412,16 @@ pub(crate) fn signature_help(
|
||||
|
||||
pub(crate) fn inlay_hint(line_index: &LineIndex, inlay_hint: InlayHint) -> lsp_ext::InlayHint {
|
||||
lsp_ext::InlayHint {
|
||||
label: inlay_hint.label.to_string(),
|
||||
text: inlay_hint.label.to_string(),
|
||||
range: range(line_index, inlay_hint.range),
|
||||
kind: match inlay_hint.kind {
|
||||
InlayKind::ParameterHint => lsp_ext::InlayKind::ParameterHint,
|
||||
InlayKind::TypeHint => lsp_ext::InlayKind::TypeHint,
|
||||
InlayKind::ChainingHint => lsp_ext::InlayKind::ChainingHint,
|
||||
},
|
||||
kind: Some(match inlay_hint.kind {
|
||||
InlayKind::ParameterHint => lsp_ext::InlayKind::Parameter,
|
||||
InlayKind::TypeHint => lsp_ext::InlayKind::Type,
|
||||
InlayKind::ChainingHint => lsp_ext::InlayKind::Other,
|
||||
}),
|
||||
description: Some("test description".to_string()),
|
||||
whitespace_before: Some(true),
|
||||
whitespace_after: Some(true),
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user