Don't allow unsafe statics outside of extern blocks
This commit is contained in:
parent
5affbb1715
commit
2f5a84ea16
6 changed files with 35 additions and 2 deletions
|
@ -224,6 +224,13 @@ pub struct InvalidSafetyOnBareFn {
|
|||
pub span: Span,
|
||||
}
|
||||
|
||||
#[derive(Diagnostic)]
|
||||
#[diag(ast_passes_unsafe_static)]
|
||||
pub struct UnsafeStatic {
|
||||
#[primary_span]
|
||||
pub span: Span,
|
||||
}
|
||||
|
||||
#[derive(Diagnostic)]
|
||||
#[diag(ast_passes_bound_in_context)]
|
||||
pub struct BoundInContext<'a> {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue