aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_lsp_server/src/req.rs
diff options
context:
space:
mode:
authorEdwin Cheng <[email protected]>2019-11-19 14:56:48 +0000
committerEdwin Cheng <[email protected]>2019-11-19 14:56:48 +0000
commit4012da07fd22223660a21c65d54d10a9a632eda0 (patch)
tree1081edcfc24b16ba0d0433d40e499458039aa5f3 /crates/ra_lsp_server/src/req.rs
parent94c63d280246971983cad4fa6ce2d333e3ba9f02 (diff)
Change return type of expand_macro
Diffstat (limited to 'crates/ra_lsp_server/src/req.rs')
-rw-r--r--crates/ra_lsp_server/src/req.rs9
1 files changed, 8 insertions, 1 deletions
diff --git a/crates/ra_lsp_server/src/req.rs b/crates/ra_lsp_server/src/req.rs
index dbc0e9624..39361b7e8 100644
--- a/crates/ra_lsp_server/src/req.rs
+++ b/crates/ra_lsp_server/src/req.rs
@@ -45,11 +45,18 @@ 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")]
50pub struct ExpandedMacro {
51 pub name: String,
52 pub expansion: String,
53}
54
48pub enum ExpandMacro {} 55pub enum ExpandMacro {}
49 56
50impl Request for ExpandMacro { 57impl Request for ExpandMacro {
51 type Params = ExpandMacroParams; 58 type Params = ExpandMacroParams;
52 type Result = Option<(String, String)>; 59 type Result = Option<ExpandedMacro>;
53 const METHOD: &'static str = "rust-analyzer/expandMacro"; 60 const METHOD: &'static str = "rust-analyzer/expandMacro";
54} 61}
55 62