blob: 84425c4a8f64748d3cafed5f59bed9e652b3e4f9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
// Regression test for #89305, where a variable was erroneously reported
// as both unused and possibly-uninitialized.
//@ check-pass
//@ needs-asm-support
#![warn(unused)]
use std::arch::asm;
fn main() {
unsafe {
let x: () = asm!("nop");
//~^ WARNING: unused variable: `x`
}
}
|