]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_resolve/macros.rs
report kind of deprecated item in message
[rust.git] / src / librustc_resolve / macros.rs
index 3976e501c169feb0f46574bf1b19c53f70d5f1df..ccc7e16ae4cf667059a7e3c192d059311ce06de7 100644 (file)
@@ -1017,22 +1017,17 @@ fn check_stability_and_deprecation(
                     );
                 }
             }
-            if let Some(depr) = &stability.rustc_depr {
-                let path = pprust::path_to_string(path);
-                let (message, lint) = stability::rustc_deprecation_message(depr, &path);
-                stability::early_report_deprecation(
-                    &mut self.lint_buffer,
-                    &message,
-                    depr.suggestion,
-                    lint,
-                    span,
-                );
-            }
         }
         if let Some(depr) = &ext.deprecation {
             let path = pprust::path_to_string(&path);
-            let (message, lint) = stability::deprecation_message(depr, &path);
-            stability::early_report_deprecation(&mut self.lint_buffer, &message, None, lint, span);
+            let (message, lint) = stability::deprecation_message(depr, "macro", &path);
+            stability::early_report_deprecation(
+                &mut self.lint_buffer,
+                &message,
+                depr.suggestion,
+                lint,
+                span,
+            );
         }
     }