mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-10-31 13:04:42 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			17 lines
		
	
	
		
			353 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			17 lines
		
	
	
		
			353 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
| //@ edition:2018
 | |
| pub fn extern_fn<const N: usize>() -> impl Iterator<Item = [u8; N]> {
 | |
|     [[0; N]; N].iter().copied()
 | |
| }
 | |
| 
 | |
| pub struct ExternTy<const N: usize> {
 | |
|     pub inner: [u8; N],
 | |
| }
 | |
| 
 | |
| pub type TyAlias<const N: usize> = ExternTy<N>;
 | |
| 
 | |
| pub trait WTrait<const N: usize, const M: usize> {
 | |
|     fn hey<const P: usize>() -> usize {
 | |
|         N + M + P
 | |
|     }
 | |
| }
 | 
