rust/tests/ui/traits/bad-sized.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

10 lines
294 B
Rust
Raw Normal View History

2015-04-18 05:12:20 +00:00
trait Trait {}
pub fn main() {
2019-05-28 18:46:13 +00:00
let x: Vec<dyn Trait + Sized> = Vec::new();
//~^ ERROR only auto traits can be used as additional traits in a trait object
2018-07-10 21:10:13 +00:00
//~| ERROR the size for values of type
//~| ERROR the size for values of type
2021-03-13 16:14:18 +00:00
//~| ERROR the size for values of type
}