mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-11-04 06:56:14 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			21 lines
		
	
	
		
			270 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			21 lines
		
	
	
		
			270 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
//@ aux-build:issue-3907.rs
 | 
						|
 | 
						|
extern crate issue_3907;
 | 
						|
 | 
						|
type Foo = dyn issue_3907::Foo;
 | 
						|
 | 
						|
struct S {
 | 
						|
    name: isize
 | 
						|
}
 | 
						|
 | 
						|
impl Foo for S { //~ ERROR expected trait, found type alias `Foo`
 | 
						|
    fn bar() { }
 | 
						|
}
 | 
						|
 | 
						|
fn main() {
 | 
						|
    let s = S {
 | 
						|
        name: 0
 | 
						|
    };
 | 
						|
    s.bar();
 | 
						|
}
 |