blob: b9677851b92deb0a334e4538f0fccf1d5dc60cde (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
//@aux-build:macro_rules.rs
//@aux-build:macro_use_helper.rs
//@aux-build:proc_macro_derive.rs
//@ignore-32bit
#![feature(lint_reasons)]
#![allow(unused_imports, unreachable_code, unused_variables, dead_code, unused_attributes)]
#![allow(clippy::single_component_path_imports)]
#![warn(clippy::macro_use_imports)]
#[macro_use]
extern crate macro_use_helper as mac;
#[macro_use]
extern crate proc_macro_derive as mini_mac;
mod a {
#[expect(clippy::macro_use_imports)]
#[macro_use]
use mac;
#[expect(clippy::macro_use_imports)]
#[macro_use]
use mini_mac;
#[expect(clippy::macro_use_imports)]
#[macro_use]
use mac::inner;
#[expect(clippy::macro_use_imports)]
#[macro_use]
use mac::inner::nested;
#[derive(ClippyMiniMacroTest)]
struct Test;
fn test() {
pub_macro!();
inner_mod_macro!();
pub_in_private_macro!(_var);
function_macro!();
let v: ty_macro!() = Vec::default();
inner::try_err!();
inner::mut_mut!();
nested::string_add!();
}
}
// issue #7015, ICE due to calling `module_children` with local `DefId`
#[macro_use]
use a as b;
fn main() {}
|