1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
// check-pass #![allow(dead_code)] macro_rules! m { () => { 0 } } trait T { const C: i32 = m!(); } struct S; impl S { const C: i32 = m!(); } fn main() {}