summaryrefslogtreecommitdiffstats
path: root/src/test/ui/parser/trait-object-polytrait-priority.rs
blob: 63425f3e2018679091e4740dbf143e3b564f266a (plain)
1
2
3
4
5
6
7
8
9
10
#![allow(bare_trait_objects)]

trait Trait<'a> {}

fn main() {
    let _: &for<'a> Trait<'a> + 'static;
    //~^ ERROR expected a path on the left-hand side of `+`, not `&for<'a> Trait<'a>`
    //~| HELP try adding parentheses
    //~| SUGGESTION &(for<'a> Trait<'a> + 'static)
}