about summary refs log tree commit diff
path: root/tests/ui
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2022-04-24 12:06:08 +0000
committerbors <bors@rust-lang.org>2022-04-24 12:06:08 +0000
commit2a5ee682cc60e2cbb0edaa1e97e171f934ed309b (patch)
treee8ec98020a07e20d99d22ae5a1cd675cfc02c729 /tests/ui
parentcef882cc9dfae7980a1712609f8d00bfaf78062c (diff)
parentf20e890a4b53848771f2041312cd52d31fb015bc (diff)
downloadrust-2a5ee682cc60e2cbb0edaa1e97e171f934ed309b.tar.gz
rust-2a5ee682cc60e2cbb0edaa1e97e171f934ed309b.zip
Auto merge of #8736 - Serial-ATA:issue-8732, r=xFrednet
Add macro export exemption to `redundant_pub_crate`

changelog: Add macro export exemption to `redundant_pub_crate`
closes #8732
Diffstat (limited to 'tests/ui')
-rw-r--r--tests/ui/redundant_pub_crate.fixed10
-rw-r--r--tests/ui/redundant_pub_crate.rs10
2 files changed, 20 insertions, 0 deletions
diff --git a/tests/ui/redundant_pub_crate.fixed b/tests/ui/redundant_pub_crate.fixed
index 25f2fd061b8..106947de68c 100644
--- a/tests/ui/redundant_pub_crate.fixed
+++ b/tests/ui/redundant_pub_crate.fixed
@@ -104,4 +104,14 @@ mod m4 {
 
 pub use m4::*;
 
+mod issue_8732 {
+    #[allow(unused_macros)]
+    macro_rules! some_macro {
+        () => {};
+    }
+
+    #[allow(unused_imports)]
+    pub(crate) use some_macro; // ok: macro exports are exempt
+}
+
 fn main() {}
diff --git a/tests/ui/redundant_pub_crate.rs b/tests/ui/redundant_pub_crate.rs
index 616286b4f39..f96cfd31843 100644
--- a/tests/ui/redundant_pub_crate.rs
+++ b/tests/ui/redundant_pub_crate.rs
@@ -104,4 +104,14 @@ mod m4 {
 
 pub use m4::*;
 
+mod issue_8732 {
+    #[allow(unused_macros)]
+    macro_rules! some_macro {
+        () => {};
+    }
+
+    #[allow(unused_imports)]
+    pub(crate) use some_macro; // ok: macro exports are exempt
+}
+
 fn main() {}