Files
rust/tests/ui/attributes/invalid_macro_export_argument.rs
Jonathan Brouwer f7fa83ec62 Changes to uitests for macro_export port
Co-authored-by: Anne Stijns <anstijns@gmail.com>
2025-09-21 10:42:47 -04:00

46 lines
925 B
Rust

//@ revisions: deny allow
//@[allow] check-pass
#![cfg_attr(deny, deny(invalid_macro_export_arguments))]
#![cfg_attr(allow, allow(invalid_macro_export_arguments))]
#[macro_export(hello, world)]
//[deny]~^ ERROR valid forms for the attribute are
//[deny]~| WARN this was previously accepted
macro_rules! a {
() => ()
}
#[macro_export(not_local_inner_macros)]
//[deny]~^ ERROR valid forms for the attribute are
//[deny]~| WARN this was previously accepted
macro_rules! b {
() => ()
}
#[macro_export]
macro_rules! c {
() => ()
}
#[macro_export(local_inner_macros)]
macro_rules! d {
() => ()
}
#[macro_export()]
//[deny]~^ ERROR valid forms for the attribute are
//[deny]~| WARN this was previously accepted
macro_rules! e {
() => ()
}
#[macro_export("blah")]
//[deny]~^ ERROR valid forms for the attribute are
//[deny]~| WARN this was previously accepted
macro_rules! f {
() => ()
}
fn main() {}