diff --git a/Cargo.lock b/Cargo.lock index 49fddef4b9f..6aa7e1ce16c 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -662,9 +662,9 @@ dependencies = [ [[package]] name = "lsp-types" -version = "0.71.0" +version = "0.72.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "efa6b75633b0c3412ee36fc416e6d9c1e4ff576b536217f4ac3f34ac83d9e564" +checksum = "face91691e558746745dc9dc6c67a4e2a24e044926e274d8378e6f19659329f0" dependencies = [ "base64", "bitflags", diff --git a/crates/ra_cargo_watch/Cargo.toml b/crates/ra_cargo_watch/Cargo.toml index 1fdbffea18c..731d50371a3 100644 --- a/crates/ra_cargo_watch/Cargo.toml +++ b/crates/ra_cargo_watch/Cargo.toml @@ -6,7 +6,7 @@ authors = ["rust-analyzer developers"] [dependencies] crossbeam-channel = "0.4.0" -lsp-types = { version = "0.71.0", features = ["proposed"] } +lsp-types = { version = "0.72.0", features = ["proposed"] } log = "0.4.8" cargo_metadata = "0.9.1" serde_json = "1.0.48" diff --git a/crates/rust-analyzer/Cargo.toml b/crates/rust-analyzer/Cargo.toml index d00545121bc..b14ebb26866 100644 --- a/crates/rust-analyzer/Cargo.toml +++ b/crates/rust-analyzer/Cargo.toml @@ -20,7 +20,7 @@ globset = "0.4.4" itertools = "0.8.2" jod-thread = "0.1.0" log = "0.4.8" -lsp-types = { version = "0.71.0", features = ["proposed"] } +lsp-types = { version = "0.72.0", features = ["proposed"] } parking_lot = "0.10.0" pico-args = "0.3.1" rand = { version = "0.7.3", features = ["small_rng"] } diff --git a/crates/rust-analyzer/src/req.rs b/crates/rust-analyzer/src/req.rs index fd6aef59719..a3efe3b9feb 100644 --- a/crates/rust-analyzer/src/req.rs +++ b/crates/rust-analyzer/src/req.rs @@ -42,14 +42,14 @@ impl Request for SyntaxTree { const METHOD: &'static str = "rust-analyzer/syntaxTree"; } -#[derive(Deserialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct SyntaxTreeParams { pub text_document: TextDocumentIdentifier, pub range: Option, } -#[derive(Serialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct ExpandedMacro { pub name: String, @@ -64,7 +64,7 @@ impl Request for ExpandMacro { const METHOD: &'static str = "rust-analyzer/expandMacro"; } -#[derive(Deserialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct ExpandMacroParams { pub text_document: TextDocumentIdentifier, @@ -79,7 +79,7 @@ impl Request for FindMatchingBrace { const METHOD: &'static str = "rust-analyzer/findMatchingBrace"; } -#[derive(Deserialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct FindMatchingBraceParams { pub text_document: TextDocumentIdentifier, @@ -101,14 +101,14 @@ impl Notification for PublishDecorations { const METHOD: &'static str = "rust-analyzer/publishDecorations"; } -#[derive(Serialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct PublishDecorationsParams { pub uri: Url, pub decorations: Vec, } -#[derive(Serialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct Decoration { pub range: Range, @@ -132,7 +132,7 @@ impl Request for JoinLines { const METHOD: &'static str = "rust-analyzer/joinLines"; } -#[derive(Deserialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct JoinLinesParams { pub text_document: TextDocumentIdentifier, @@ -162,7 +162,7 @@ pub struct RunnablesParams { pub position: Option, } -#[derive(Serialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct Runnable { pub range: Range, @@ -173,7 +173,7 @@ pub struct Runnable { pub cwd: Option, } -#[derive(Serialize, Debug)] +#[derive(Deserialize, Serialize, Debug)] #[serde(rename_all = "camelCase")] pub struct SourceChange { pub label: String, diff --git a/crates/rust-analyzer/src/semantic_tokens.rs b/crates/rust-analyzer/src/semantic_tokens.rs index 1b146e4d87e..d9ba770509e 100644 --- a/crates/rust-analyzer/src/semantic_tokens.rs +++ b/crates/rust-analyzer/src/semantic_tokens.rs @@ -49,12 +49,9 @@ SemanticTokenModifier::DOCUMENTATION, SemanticTokenModifier::DECLARATION, SemanticTokenModifier::DEFINITION, - SemanticTokenModifier::REFERENCE, SemanticTokenModifier::STATIC, SemanticTokenModifier::ABSTRACT, SemanticTokenModifier::DEPRECATED, - SemanticTokenModifier::ASYNC, - SemanticTokenModifier::VOLATILE, SemanticTokenModifier::READONLY, CONSTANT, MUTABLE,