rust/src/test/ui/span/macro-ty-params.rs

14 lines
308 B
Rust
Raw Normal View History

macro_rules! m {
($p1: path) => {
#[derive($p1)] struct U;
}
}
macro_rules! foo { () => () }
fn main() {
2017-11-20 06:13:27 -06:00
foo::<T>!(); //~ ERROR generic arguments in macro path
foo::<>!(); //~ ERROR generic arguments in macro path
m!(Default<>); //~ ERROR unexpected generic arguments in path
}