2 #[deny(bare_trait_objects)]
4 fn function(x: &SomeTrait, y: Box<SomeTrait>) {
5 //~^ ERROR trait objects without an explicit `dyn` are deprecated
6 //~| WARN this is accepted in the current edition
7 //~| ERROR trait objects without an explicit `dyn` are deprecated
8 //~| WARN this is accepted in the current edition
9 let _x: &SomeTrait = todo!();
10 //~^ ERROR trait objects without an explicit `dyn` are deprecated
11 //~| WARN this is accepted in the current edition