migrate: non_ascii_idents.rs

This commit is contained in:
Rejyr 2022-09-05 15:05:19 -04:00
parent 384010b9f4
commit 3f69c1b523
2 changed files with 49 additions and 35 deletions

View file

@ -6,6 +6,32 @@ use rustc_span::{symbol::Ident, Span, Symbol};
use crate::LateContext;
#[derive(LintDiagnostic)]
#[diag(lint_identifier_non_ascii_char)]
pub struct IdentifierNonAsciiChar;
#[derive(LintDiagnostic)]
#[diag(lint_identifier_uncommon_codepoints)]
pub struct IdentifierUncommonCodepoints;
#[derive(LintDiagnostic)]
#[diag(lint_confusable_identifier_pair)]
pub struct ConfusableIdentifierPair {
pub existing_sym: Symbol,
pub sym: Symbol,
#[label]
pub label: Span,
}
#[derive(LintDiagnostic)]
#[diag(lint_mixed_script_confusables)]
#[note(includes_note)]
#[note]
pub struct MixedScriptConfusables {
pub set: String,
pub includes: String,
}
pub struct NonFmtPanicUnused {
pub count: usize,
pub suggestion: Option<Span>,