mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-10-30 20:44:34 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			24 lines
		
	
	
		
			369 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			24 lines
		
	
	
		
			369 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
| #![crate_name = "foo"]
 | |
| 
 | |
| pub trait Some {}
 | |
| impl Some for () {}
 | |
| pub trait Other {}
 | |
| impl Other for () {}
 | |
| 
 | |
| pub fn alef<T: Some>() -> T {
 | |
|     loop {}
 | |
| }
 | |
| pub fn alpha() -> impl Some {}
 | |
| 
 | |
| pub fn bet<T, U>(t: T) -> U {
 | |
|     loop {}
 | |
| }
 | |
| pub fn beta<T>(t: T) -> T {}
 | |
| 
 | |
| pub fn other<T: Other, U: Other>(t: T, u: U) {
 | |
|     loop {}
 | |
| }
 | |
| pub fn alternate<T: Other>(t: T, u: T) {
 | |
|     loop {}
 | |
| }
 | 
