aboutsummaryrefslogtreecommitdiff
path: root/crates/proc_macro_srv/src/proc_macro
diff options
context:
space:
mode:
Diffstat (limited to 'crates/proc_macro_srv/src/proc_macro')
-rw-r--r--crates/proc_macro_srv/src/proc_macro/diagnostic.rs9
1 files changed, 2 insertions, 7 deletions
diff --git a/crates/proc_macro_srv/src/proc_macro/diagnostic.rs b/crates/proc_macro_srv/src/proc_macro/diagnostic.rs
index 55d93917c..9ceda2a47 100644
--- a/crates/proc_macro_srv/src/proc_macro/diagnostic.rs
+++ b/crates/proc_macro_srv/src/proc_macro/diagnostic.rs
@@ -91,7 +91,7 @@ impl<'a> Iterator for Children<'a> {
91impl Diagnostic { 91impl Diagnostic {
92 /// Creates a new diagnostic with the given `level` and `message`. 92 /// Creates a new diagnostic with the given `level` and `message`.
93 pub fn new<T: Into<String>>(level: Level, message: T) -> Diagnostic { 93 pub fn new<T: Into<String>>(level: Level, message: T) -> Diagnostic {
94 Diagnostic { level: level, message: message.into(), spans: vec![], children: vec![] } 94 Diagnostic { level, message: message.into(), spans: vec![], children: vec![] }
95 } 95 }
96 96
97 /// Creates a new diagnostic with the given `level` and `message` pointing to 97 /// Creates a new diagnostic with the given `level` and `message` pointing to
@@ -101,12 +101,7 @@ impl Diagnostic {
101 S: MultiSpan, 101 S: MultiSpan,
102 T: Into<String>, 102 T: Into<String>,
103 { 103 {
104 Diagnostic { 104 Diagnostic { level, message: message.into(), spans: spans.into_spans(), children: vec![] }
105 level: level,
106 message: message.into(),
107 spans: spans.into_spans(),
108 children: vec![],
109 }
110 } 105 }
111 106
112 diagnostic_child_methods!(span_error, error, Level::Error); 107 diagnostic_child_methods!(span_error, error, Level::Error);