daily pastebin goal
24%
SHARE
TWEET

Untitled

a guest Jan 11th, 2019 55 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. fn main() {
  2.     let foo = Some(&0);
  3.     let int = &Some(0);
  4.     let bar: Option<&u8> = unsafe { std::mem::transmute(int) };
  5.     assert_eq!(foo, bar);
  6. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top