mirror of
				https://github.com/rust-lang/rust.git
				synced 2025-10-31 13:04:42 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			17 lines
		
	
	
		
			433 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
			
		
		
	
	
			17 lines
		
	
	
		
			433 B
		
	
	
	
		
			Rust
		
	
	
	
	
	
| // This test ensures that the 2024 edition merged doctest will not use `#[allow(unused)]`.
 | |
| 
 | |
| //@ edition: 2024
 | |
| //@ compile-flags:--test
 | |
| //@ normalize-stdout: "tests/rustdoc-ui/doctest" -> "$$DIR"
 | |
| //@ normalize-stdout: "finished in \d+\.\d+s" -> "finished in $$TIME"
 | |
| //@ failure-status: 101
 | |
| 
 | |
| #![doc(test(attr(allow(unused_variables), deny(warnings))))]
 | |
| 
 | |
| /// Example
 | |
| ///
 | |
| /// ```rust,no_run
 | |
| /// trait T { fn f(); }
 | |
| /// ```
 | |
| pub fn f() {}
 | 
