Make extern blocks without unsafe warn in edition 2024
This commit is contained in:
parent
46cd80b691
commit
3ba8de0b60
10 changed files with 78 additions and 7 deletions
|
@ -205,6 +205,9 @@ pub(super) fn decorate_lint(sess: &Session, diagnostic: BuiltinLintDiag, diag: &
|
|||
};
|
||||
lints::DeprecatedWhereClauseLocation { suggestion }.decorate_lint(diag);
|
||||
}
|
||||
BuiltinLintDiag::MissingUnsafeOnExtern => {
|
||||
lints::MissingUnsafeOnExtern.decorate_lint(diag);
|
||||
}
|
||||
BuiltinLintDiag::SingleUseLifetime {
|
||||
param_span,
|
||||
use_span: Some((use_span, elide)),
|
||||
|
|
|
@ -2738,6 +2738,10 @@ pub enum DeprecatedWhereClauseLocationSugg {
|
|||
},
|
||||
}
|
||||
|
||||
#[derive(LintDiagnostic)]
|
||||
#[diag(lint_missing_unsafe_on_extern)]
|
||||
pub struct MissingUnsafeOnExtern;
|
||||
|
||||
#[derive(LintDiagnostic)]
|
||||
#[diag(lint_single_use_lifetime)]
|
||||
pub struct SingleUseLifetime {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue