aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_proc_macro_srv/src/lib.rs
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2020-04-06 16:08:26 +0100
committerGitHub <[email protected]>2020-04-06 16:08:26 +0100
commitf6d688d13070a54b288486900a30680d013c66ca (patch)
tree39262a1e6cb34897723c4c36b7503fc1483c5a9f /crates/ra_proc_macro_srv/src/lib.rs
parent2603a9e628d304c8cb8fd08979e2f9c9afeac69e (diff)
parent4f70162f54ceaa4ff68a5ab74e31b5dda7ac9444 (diff)
Merge #3842
3842: Add lib-proc-macro mod in ra_proc_macro_srv r=matklad a=edwin0cheng This PR add a module in ra_proc_macro_srv, which is just copy & paste from rustc lib_proc_macro and remove all unstable features in it. The main idea here is by doing that, we could build the `ra_proc_macro_srv` without nightly compiler and remain ABI compatibility. Co-authored-by: Edwin Cheng <[email protected]>
Diffstat (limited to 'crates/ra_proc_macro_srv/src/lib.rs')
-rw-r--r--crates/ra_proc_macro_srv/src/lib.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/crates/ra_proc_macro_srv/src/lib.rs b/crates/ra_proc_macro_srv/src/lib.rs
index f77be1475..80cfa1174 100644
--- a/crates/ra_proc_macro_srv/src/lib.rs
+++ b/crates/ra_proc_macro_srv/src/lib.rs
@@ -10,6 +10,11 @@
10//! * By **copying** the whole rustc `lib_proc_macro` code, we are able to build this with `stable` 10//! * By **copying** the whole rustc `lib_proc_macro` code, we are able to build this with `stable`
11//! rustc rather than `unstable`. (Although in gerenal ABI compatibility is still an issue) 11//! rustc rather than `unstable`. (Although in gerenal ABI compatibility is still an issue)
12 12
13#[allow(dead_code)]
14#[doc(hidden)]
15mod proc_macro;
16
17use proc_macro::bridge::client::TokenStream;
13use ra_proc_macro::{ExpansionResult, ExpansionTask, ListMacrosResult, ListMacrosTask}; 18use ra_proc_macro::{ExpansionResult, ExpansionTask, ListMacrosResult, ListMacrosTask};
14 19
15pub fn expand_task(_task: &ExpansionTask) -> Result<ExpansionResult, String> { 20pub fn expand_task(_task: &ExpansionTask) -> Result<ExpansionResult, String> {