Handle assembler warnings properly

This commit is contained in:
Amanieu d'Antras 2020-06-09 14:37:59 +01:00
parent ccac43b86b
commit 5541f689e9
9 changed files with 124 additions and 15 deletions

View file

@ -37,5 +37,8 @@ fn main() {
asm!(concat!("invalid", "_", "instruction"));
//~^ ERROR: invalid instruction mnemonic 'invalid_instruction'
asm!("movaps %xmm3, (%esi, 2)", options(att_syntax));
//~^ WARN: scale factor without index register is ignored
}
}

View file

@ -70,5 +70,17 @@ note: instantiated into assembly here
LL | invalid_instruction
| ^^^^^^^^^^^^^^^^^^^
error: aborting due to 6 previous errors
warning: scale factor without index register is ignored
--> $DIR/srcloc.rs:41:15
|
LL | asm!("movaps %xmm3, (%esi, 2)", options(att_syntax));
| ^
|
note: instantiated into assembly here
--> <inline asm>:1:23
|
LL | movaps %xmm3, (%esi, 2)
| ^
error: aborting due to 6 previous errors; 1 warning emitted