mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-11-04 15:05:30 +00:00 
			
		
		
		
	Note that some of the output is currently bogus, with missing params and
args:
```
fn add(: _, : _) -> _ { m::add(, ) }
```
The next commit will fix this.
		
	
			
		
			
				
	
	
		
			23 lines
		
	
	
		
			288 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
		
			288 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
//@ pretty-compare-only
 | 
						|
//@ pretty-mode:hir
 | 
						|
//@ pp-exact:hir-delegation.pp
 | 
						|
 | 
						|
#![allow(incomplete_features)]
 | 
						|
#![feature(fn_delegation)]
 | 
						|
 | 
						|
fn b<C>(e: C) {}
 | 
						|
 | 
						|
trait G {
 | 
						|
    reuse b {}
 | 
						|
}
 | 
						|
 | 
						|
mod m {
 | 
						|
    pub fn add(a: u32, b: u32) -> u32 { a + b }
 | 
						|
}
 | 
						|
 | 
						|
reuse m::add;
 | 
						|
 | 
						|
fn main() {
 | 
						|
    _ = add(1, 2);
 | 
						|
}
 |