mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-11-04 15:05:30 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			16 lines
		
	
	
		
			348 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			16 lines
		
	
	
		
			348 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
//@ compile-flags: -Zvalidate-mir
 | 
						|
 | 
						|
// Regression test for <https://github.com/rust-lang/rust/issues/141394>.
 | 
						|
 | 
						|
#![feature(unsafe_binders)]
 | 
						|
#![allow(incomplete_features)]
 | 
						|
 | 
						|
use std::unsafe_binder::unwrap_binder;
 | 
						|
 | 
						|
fn id<T>(x: unsafe<> T) -> T {
 | 
						|
    //~^ ERROR the trait bound `T: Copy` is not satisfied
 | 
						|
    unsafe { unwrap_binder!(x) }
 | 
						|
}
 | 
						|
 | 
						|
fn main() {}
 |