mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-10-30 20:44:34 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			11 lines
		
	
	
		
			241 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			11 lines
		
	
	
		
			241 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
| fn main() {
 | |
|     struct U;
 | |
| 
 | |
|     // A tuple is a "non-reference pattern".
 | |
|     // A `mut` binding pattern resets the binding mode to by-value.
 | |
| 
 | |
|     let p = (U, U);
 | |
|     let (a, mut b) = &p;
 | |
|     //~^ ERROR cannot move out of a shared reference
 | |
| }
 | 
