llvm_asm → asm

This commit is contained in:
Ralf Jung 2021-08-16 17:34:48 +02:00
parent 9a6a5119fc
commit 2c14bab76f

View File

@ -1,4 +1,4 @@
#![feature(llvm_asm)]
#![feature(asm)]
use std::env;
@ -7,9 +7,9 @@ compile_error!("`miri` cfg should not be set in build script");
fn not_in_miri() -> i32 {
// Inline assembly definitely does not work in Miri.
let dummy = 42;
let mut dummy = 42;
unsafe {
llvm_asm!("" : : "r"(&dummy));
asm!("/* {} */", in(reg) &mut dummy);
}
return dummy;
}