Move mixed export_name/no_mangle check to check_attr.rs and improve the error
Signed-off-by: Jonathan Brouwer <jonathantbrouwer@gmail.com>
This commit is contained in:
@@ -49,6 +49,18 @@ pub(crate) struct ConstContinueAttr {
|
||||
pub node_span: Span,
|
||||
}
|
||||
|
||||
#[derive(LintDiagnostic)]
|
||||
#[diag(passes_mixed_export_name_and_no_mangle)]
|
||||
pub(crate) struct MixedExportNameAndNoMangle {
|
||||
#[label]
|
||||
#[suggestion(style = "verbose", code = "", applicability = "machine-applicable")]
|
||||
pub no_mangle_span: Span,
|
||||
#[note]
|
||||
pub export_name_span: Span,
|
||||
pub no_mangle_attr: &'static str,
|
||||
pub export_name_attr: &'static str,
|
||||
}
|
||||
|
||||
#[derive(LintDiagnostic)]
|
||||
#[diag(passes_outer_crate_level_attr)]
|
||||
pub(crate) struct OuterCrateLevelAttr;
|
||||
|
||||
Reference in New Issue
Block a user