use std::rc::Rc; struct A; fn p(x: X) { match std::mem::size_of::() { 0 => print!("0"), _ => print!("1"), } } fn main() { let a = &A; p(a); p(a.clone()); let b = &(); p(b); p(b.clone()); let c = Rc::new(()); p(Rc::clone(&c)); p(c.clone()); }