mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-10-30 20:44:34 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			16 lines
		
	
	
		
			230 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			16 lines
		
	
	
		
			230 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
| //@ check-pass
 | |
| #![allow(unused_variables)]
 | |
| 
 | |
| struct Zeroes;
 | |
| struct Foo<T>(T);
 | |
| 
 | |
| impl Into<[usize; 3]> for Zeroes {
 | |
|     fn into(self) -> [usize; 3] {
 | |
|         [0; 3]
 | |
|     }
 | |
| }
 | |
| 
 | |
| fn main() {
 | |
|     let Foo([a, b, c]) = Foo(Zeroes.into());
 | |
| }
 | 
