]> git.proxmox.com Git - rustc.git/blob - src/test/ui/llvm-asm/llvm-asm-bad-clobber.rs
New upstream version 1.44.1+dfsg1
[rustc.git] / src / test / ui / llvm-asm / llvm-asm-bad-clobber.rs
1 // ignore-android
2 // ignore-arm
3 // ignore-aarch64
4 // ignore-s390x
5 // ignore-emscripten
6 // ignore-powerpc
7 // ignore-powerpc64
8 // ignore-powerpc64le
9 // ignore-sparc
10 // ignore-sparc64
11 // ignore-mips
12 // ignore-mips64
13
14 #![feature(llvm_asm)]
15
16 #[cfg(any(target_arch = "x86",
17 target_arch = "x86_64"))]
18
19 pub fn main() {
20 unsafe {
21 // clobber formatted as register input/output
22 llvm_asm!("xor %eax, %eax" : : : "{eax}");
23 //~^ ERROR clobber should not be surrounded by braces
24 }
25 }