mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-10-31 13:04:42 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			10 lines
		
	
	
		
			215 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			10 lines
		
	
	
		
			215 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
| struct Foo {}
 | |
| 
 | |
| pub fn main() {
 | |
|     let mut tups = vec![(Foo {}, Foo {})];
 | |
|     // The below desugars to &(ref n, mut m).
 | |
|     for (n, mut m) in &tups {
 | |
|         //~^ ERROR cannot move out of a shared reference
 | |
|     }
 | |
| }
 | 
