Static rustc_lint::builtin::NAMED_ASM_LABELS [−][src]
pub static NAMED_ASM_LABELS: &Lint
Expand description
The named_asm_labels
lint detects the use of named labels in the
inline asm!
macro.
Example
ⓘ
#![feature(asm)]
fn main() {
unsafe {
asm!("foo: bar");
}
}
{{produces}}
Explanation
LLVM is allowed to duplicate inline assembly blocks for any reason, for example when it is in a function that gets inlined. Because of this, GNU assembler local labels must be used instead of labels with a name. Using named labels might cause assembler or linker errors.
See the unstable book for more details.