Only emit lint for local macros
This commit is contained in:
parent
886dea2bcd
commit
cf167c9c9c
3 changed files with 32 additions and 7 deletions
|
|
@ -0,0 +1,4 @@
|
|||
#[macro_export]
|
||||
macro_rules! my_macro {
|
||||
() => { true; }
|
||||
}
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
// aux-build:foreign-crate.rs
|
||||
// check-pass
|
||||
|
||||
extern crate foreign_crate;
|
||||
|
||||
// Test that we do not lint for a macro in a foreign crate
|
||||
fn main() {
|
||||
let _ = foreign_crate::my_macro!();
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue