Advertisement
Guest User

Untitled

a guest
Aug 19th, 2019
102
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.17 KB | None | 0 0
  1. use std::sync::Arc;
  2. fn hm(item: Option<&u32>) {
  3. println!("{:#?}", item);
  4. }
  5.  
  6. fn main() {
  7. let test = Some(Arc::new(5));
  8. hm(test.as_ref().map(|i| i.as_ref()));
  9. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement