Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- fn sub(a: Box<i32>) {
- println!("sub: {}", a);
- }
- fn main() {
- let y = 13i32;
- let x = Box::new(y);
- sub(x);
- println!("main: {}", y);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement