]> git.lizzy.rs Git - rust.git/blob - tests/ui/suggestions/object-unsafe-trait-should-use-where-sized.rs
Rollup merge of #106798 - scottmcm:signum-via-cmp, r=Mark-Simulacrum
[rust.git] / tests / ui / suggestions / object-unsafe-trait-should-use-where-sized.rs
1 // run-rustfix
2 #![allow(unused_variables, dead_code)]
3
4 trait Trait {
5     fn foo() where Self: Other, { }
6     fn bar(self: ()) {} //~ ERROR invalid `self` parameter type
7 }
8
9 fn bar(x: &dyn Trait) {} //~ ERROR the trait `Trait` cannot be made into an object
10
11 trait Other {}
12
13 fn main() {}