1 // Test related to when a region bound is required to be specified.
3 trait IsStatic : 'static { }
4 trait IsSend : Send { }
9 // Bounds on object types:
11 struct Foo<'a,'b,'c> { //~ ERROR parameter `'c` is never used
12 // All of these are ok, because we can derive exactly one bound:
17 e: Box<Is<'a>+Send>, // we can derive two bounds, but one is 'static, so ok
18 f: Box<SomeTrait>, // OK, defaults to 'static due to RFC 599.
22 //~^ ERROR only a single explicit lifetime bound is permitted
23 //~| ERROR lifetime bound not satisfied
30 B:Is<'a>+Is2<'b>, // OK in a parameter, but not an object type.
32 D:Is<'a>+Is2<'static>,
33 E:'a+'b // OK in a parameter, but not an object type.