diff options
Diffstat (limited to 'crates/ra_lsp_server/src/req.rs')
-rw-r--r-- | crates/ra_lsp_server/src/req.rs | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/crates/ra_lsp_server/src/req.rs b/crates/ra_lsp_server/src/req.rs index d25fc5726..39361b7e8 100644 --- a/crates/ra_lsp_server/src/req.rs +++ b/crates/ra_lsp_server/src/req.rs | |||
@@ -45,6 +45,28 @@ pub struct SyntaxTreeParams { | |||
45 | pub range: Option<Range>, | 45 | pub range: Option<Range>, |
46 | } | 46 | } |
47 | 47 | ||
48 | #[derive(Serialize, Debug)] | ||
49 | #[serde(rename_all = "camelCase")] | ||
50 | pub struct ExpandedMacro { | ||
51 | pub name: String, | ||
52 | pub expansion: String, | ||
53 | } | ||
54 | |||
55 | pub enum ExpandMacro {} | ||
56 | |||
57 | impl Request for ExpandMacro { | ||
58 | type Params = ExpandMacroParams; | ||
59 | type Result = Option<ExpandedMacro>; | ||
60 | const METHOD: &'static str = "rust-analyzer/expandMacro"; | ||
61 | } | ||
62 | |||
63 | #[derive(Deserialize, Debug)] | ||
64 | #[serde(rename_all = "camelCase")] | ||
65 | pub struct ExpandMacroParams { | ||
66 | pub text_document: TextDocumentIdentifier, | ||
67 | pub position: Option<Position>, | ||
68 | } | ||
69 | |||
48 | pub enum SelectionRangeRequest {} | 70 | pub enum SelectionRangeRequest {} |
49 | 71 | ||
50 | impl Request for SelectionRangeRequest { | 72 | impl Request for SelectionRangeRequest { |