rust/tests/ui/attributes/attrs-with-no-formal-in-generics-2.rs

13 lines
357 B
Rust
Raw Normal View History

// This test checks variations on `<#[attr] 'a, #[oops]>`, where
// `#[oops]` is left dangling (that is, it is unattached, with no
// formal binding following it).
#![feature(rustc_attrs)]
struct RefAny<'a, T>(&'a T);
impl<#[rustc_dummy] 'a, #[rustc_dummy] T, #[oops]> RefAny<'a, T> {}
2019-02-07 03:10:11 -06:00
//~^ ERROR trailing attribute after generic parameter
fn main() {}