]> git.lizzy.rs Git - rust.git/blob - src/test/ui/drop-bounds/drop-bounds.rs
Rollup merge of #89468 - FabianWolff:issue-89358, r=jackh726
[rust.git] / src / test / ui / drop-bounds / drop-bounds.rs
1 #![deny(drop_bounds)]
2 fn foo<T: Drop>() {} //~ ERROR
3 fn bar<U>()
4 where
5     U: Drop, //~ ERROR
6 {
7 }
8 fn baz(_x: impl Drop) {} //~ ERROR
9 struct Foo<T: Drop> { //~ ERROR
10   _x: T
11 }
12 struct Bar<U> where U: Drop { //~ ERROR
13   _x: U
14 }
15 trait Baz: Drop { //~ ERROR
16 }
17 impl<T: Drop> Baz for T { //~ ERROR
18 }
19 fn main() {}