mirror of
https://github.com/rust-lang/rust.git
synced 2025-06-06 12:18:33 +00:00
16 lines
348 B
Rust
16 lines
348 B
Rust
![]() |
//@ run-rustfix
|
||
|
#![feature(stmt_expr_attributes)]
|
||
|
#![allow(unused_assignments, unused_attributes)]
|
||
|
|
||
|
fn main() {
|
||
|
let mut x = #[deprecated] 1 + 2; //~ ERROR ambiguous
|
||
|
|
||
|
#[deprecated] x = 4; //~ ERROR ambiguous
|
||
|
|
||
|
x = #[deprecated] 5 as i32; //~ ERROR ambiguous
|
||
|
|
||
|
let _r = #[deprecated] 1..6; //~ ERROR ambiguous
|
||
|
|
||
|
println!("{}", x);
|
||
|
}
|