Guest User

Untitled

a guest
Jun 22nd, 2018
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.21 KB | None | 0 0
  1. /*
  2. Assuming this code compiles:
  3.  
  4. ```
  5. let n = &mut 42;
  6. foo(n);
  7. ```
  8.  
  9. Does the following code compile?
  10.  
  11. ```
  12. let n = &mut 42;
  13. foo(n);
  14. foo(n);
  15. ```
  16. */
  17.  
  18. fn foo(x: &mut i32) {}
  19. fn main(){
  20. let n = &mut 42;
  21. foo(n);
  22. foo(n);
  23. }
Add Comment
Please, Sign In to add comment