2021-03-16 21:47:06 +01:00
|
|
|
//@ edition:2021
|
|
|
|
|
|
|
|
fn function(x: &SomeTrait, y: Box<SomeTrait>) {
|
2024-10-04 16:10:28 +02:00
|
|
|
//~^ ERROR expected a type, found a trait
|
|
|
|
//~| ERROR expected a type, found a trait
|
2021-03-16 21:47:06 +01:00
|
|
|
let _x: &SomeTrait = todo!();
|
2024-10-04 16:10:28 +02:00
|
|
|
//~^ ERROR expected a type, found a trait
|
2021-03-16 21:47:06 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
trait SomeTrait {}
|
|
|
|
|
|
|
|
fn main() {}
|