2017-02-22 14:59:40 -06:00
|
|
|
// A few contrived examples where lifetime should (or should not) be parsed as an object type.
|
|
|
|
// Lifetimes parsed as types are still rejected later by semantic checks.
|
|
|
|
|
|
|
|
// `'static` is a lifetime, `'static +` is a type, `'a` is a type
|
|
|
|
fn g() where
|
|
|
|
'static: 'static,
|
2019-05-28 13:46:13 -05:00
|
|
|
dyn 'static +: 'static + Copy,
|
2019-06-21 11:12:28 -05:00
|
|
|
//~^ ERROR at least one trait is required for an object type
|
2017-02-22 14:59:40 -06:00
|
|
|
{}
|
|
|
|
|
|
|
|
fn main() {}
|