// run-rustfix #![warn(clippy::all)] #![allow(clippy::boxed_local, clippy::needless_pass_by_value)] #![allow(clippy::blacklisted_name, unused_variables, dead_code)] use std::boxed::Box; use std::rc::Rc; pub struct MyStruct {} pub struct SubT { foo: T, } pub enum MyEnum { One, Two, } // Rc<&T> pub fn test1(foo: Rc<&T>) {} pub fn test2(foo: Rc<&MyStruct>) {} pub fn test3(foo: Rc<&MyEnum>) {} pub fn test4_neg(foo: Rc>) {} // Rc> pub fn test5(a: Rc>) {} // Rc> pub fn test6(a: Rc>) {} // Box<&T> pub fn test7(foo: Box<&T>) {} pub fn test8(foo: Box<&MyStruct>) {} pub fn test9(foo: Box<&MyEnum>) {} pub fn test10_neg(foo: Box>) {} fn main() {}