Skip to content

Commit

Permalink
feat(inlayHint): add inlayHint provider
Browse files Browse the repository at this point in the history
  • Loading branch information
sno2 committed Mar 21, 2022
1 parent 29a50e7 commit 69f21e7
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/inlay_hint.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@ use crate::{
};
use serde::{Deserialize, Serialize};

#[derive(Debug, Eq, PartialEq, Clone, Deserialize, Serialize)]
#[serde(rename_all = "camelCase")]
#[serde(untagged)]
pub enum InlayHintServerCapabilities {
Options(InlayHintOptions),
RegistrationOptions(InlayHintRegistrationOptions),
}

#[derive(Debug, Eq, PartialEq, Clone, Default, Deserialize, Serialize)]
#[serde(rename_all = "camelCase")]
pub struct InlayHintClientCapabilitiesResolveSupport {
Expand Down
7 changes: 7 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1852,6 +1852,13 @@ pub struct ServerCapabilities {
#[serde(skip_serializing_if = "Option::is_none")]
pub moniker_provider: Option<OneOf<bool, MonikerServerCapabilities>>,

/// The server provides inlay hints.
///
/// @since 3.17.0 - proposed state
#[serde(skip_serializing_if = "Option::is_none")]
#[cfg(feature = "proposed")]
pub inlay_hint_provider: Option<OneOf<bool, InlayHintServerCapabilities>>,

/// The server provides linked editing range support.
///
/// @since 3.16.0
Expand Down

0 comments on commit 69f21e7

Please sign in to comment.