lint: port unstable feature diagnostics
Signed-off-by: David Wood <david.wood@huawei.com>
This commit is contained in:
parent
d071f504f8
commit
23ee3e0914
2 changed files with 3 additions and 1 deletions
|
@ -352,3 +352,5 @@ lint-builtin-const-no-mangle = const items should never be `#[no_mangle]`
|
|||
|
||||
lint-builtin-mutable-transmutes =
|
||||
transmuting &T to &mut T is undefined behavior, even if the reference is unused, consider instead using an UnsafeCell
|
||||
|
||||
lint-builtin-unstable-features = unstable feature
|
||||
|
|
|
@ -1323,7 +1323,7 @@ impl<'tcx> LateLintPass<'tcx> for UnstableFeatures {
|
|||
if let Some(items) = attr.meta_item_list() {
|
||||
for item in items {
|
||||
cx.struct_span_lint(UNSTABLE_FEATURES, item.span(), |lint| {
|
||||
lint.build("unstable feature").emit();
|
||||
lint.build(fluent::lint::builtin_unstable_features).emit();
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue