lint: port asm labels diagnostics
Signed-off-by: David Wood <david.wood@huawei.com>
This commit is contained in:
parent
5524ca1a1d
commit
fedd4c63f8
2 changed files with 3 additions and 3 deletions
|
@ -396,3 +396,5 @@ lint-builtin-clashing-extern-diff-name = `{$this_fi}` redeclares `{$orig}` with
|
|||
|
||||
lint-builtin-deref-nullptr = dereferencing a null pointer
|
||||
.label = this code causes undefined behavior when executed
|
||||
|
||||
lint-builtin-asm-labels = avoid using named labels in inline assembly
|
||||
|
|
|
@ -3182,9 +3182,7 @@ impl<'tcx> LateLintPass<'tcx> for NamedAsmLabels {
|
|||
NAMED_ASM_LABELS,
|
||||
Some(target_spans),
|
||||
|diag| {
|
||||
let mut err =
|
||||
diag.build("avoid using named labels in inline assembly");
|
||||
err.emit();
|
||||
diag.build(fluent::lint::builtin_asm_labels).emit();
|
||||
},
|
||||
BuiltinLintDiagnostics::NamedAsmLabel(
|
||||
"only local labels of the form `<number>:` should be used in inline asm"
|
||||
|
|
Loading…
Add table
Reference in a new issue