2021-02-28 14:51:44 -05:00
|
|
|
//@ check-pass
|
|
|
|
//@ compile-flags: -Z span-debug --error-format human
|
|
|
|
//@ aux-build:test-macros.rs
|
|
|
|
|
|
|
|
#![feature(rustc_attrs)]
|
|
|
|
#![feature(stmt_expr_attributes)]
|
|
|
|
|
|
|
|
#![no_std] // Don't load unnecessary hygiene information from std
|
|
|
|
extern crate std;
|
|
|
|
|
|
|
|
#[macro_use]
|
|
|
|
extern crate test_macros;
|
|
|
|
|
|
|
|
macro_rules! produce_it {
|
|
|
|
($expr:expr) => {
|
|
|
|
#[derive(Print)]
|
2024-08-21 15:01:10 +10:00
|
|
|
struct Foo(
|
|
|
|
[bool; #[cfg_attr(not(FALSE), rustc_dummy(first))] $expr]
|
|
|
|
);
|
2021-02-28 14:51:44 -05:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
produce_it!(#[cfg_attr(not(FALSE), rustc_dummy(second))] {
|
2024-08-21 15:01:10 +10:00
|
|
|
#![cfg_attr(not(FALSE), rustc_dummy(third))]
|
|
|
|
#[cfg_attr(not(FALSE), rustc_dummy(fourth))]
|
2021-02-28 14:51:44 -05:00
|
|
|
30
|
|
|
|
});
|
|
|
|
|
|
|
|
fn main() {}
|