1 // Test that the compiler will catch invalid inline assembly constraints.
13 bad_register_constraint();
19 fn bad_register_constraint() {
22 asm!("" :"={rax"(rax)) //~ ERROR E0668
24 println!("Accumulator is: {}", rax);
30 asm!("callq $0" : : "0"(foo)) //~ ERROR E0668
34 fn wrong_size_output() {
37 asm!("addb $1, $0" : "={rax}"((0i32, rax))); //~ ERROR E0668
39 println!("rax: {}", rax);