Rename IntoDiagnosticArg as IntoDiagArg.
Also rename `into_diagnostic_arg` as `into_diag_arg`, and `NotIntoDiagnosticArg` as `NotInotDiagArg`.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
use hir::GenericParamKind;
|
||||
use rustc_errors::{
|
||||
codes::*, AddToDiagnostic, Applicability, Diag, DiagMessage, DiagStyledString,
|
||||
EmissionGuarantee, IntoDiagnosticArg, MultiSpan, SubdiagMessageOp,
|
||||
EmissionGuarantee, IntoDiagArg, MultiSpan, SubdiagMessageOp,
|
||||
};
|
||||
use rustc_hir as hir;
|
||||
use rustc_hir::FnRetTy;
|
||||
@@ -537,11 +537,11 @@ pub enum TyOrSig<'tcx> {
|
||||
ClosureSig(Highlighted<'tcx, Binder<'tcx, FnSig<'tcx>>>),
|
||||
}
|
||||
|
||||
impl IntoDiagnosticArg for TyOrSig<'_> {
|
||||
fn into_diagnostic_arg(self) -> rustc_errors::DiagArgValue {
|
||||
impl IntoDiagArg for TyOrSig<'_> {
|
||||
fn into_diag_arg(self) -> rustc_errors::DiagArgValue {
|
||||
match self {
|
||||
TyOrSig::Ty(ty) => ty.into_diagnostic_arg(),
|
||||
TyOrSig::ClosureSig(sig) => sig.into_diagnostic_arg(),
|
||||
TyOrSig::Ty(ty) => ty.into_diag_arg(),
|
||||
TyOrSig::ClosureSig(sig) => sig.into_diag_arg(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
use crate::fluent_generated as fluent;
|
||||
use crate::infer::error_reporting::nice_region_error::find_anon_type;
|
||||
use rustc_errors::{AddToDiagnostic, Diag, EmissionGuarantee, IntoDiagnosticArg, SubdiagMessageOp};
|
||||
use rustc_errors::{AddToDiagnostic, Diag, EmissionGuarantee, IntoDiagArg, SubdiagMessageOp};
|
||||
use rustc_middle::ty::{self, TyCtxt};
|
||||
use rustc_span::{symbol::kw, Span};
|
||||
|
||||
@@ -107,8 +107,8 @@ pub enum SuffixKind {
|
||||
ReqByBinding,
|
||||
}
|
||||
|
||||
impl IntoDiagnosticArg for PrefixKind {
|
||||
fn into_diagnostic_arg(self) -> rustc_errors::DiagArgValue {
|
||||
impl IntoDiagArg for PrefixKind {
|
||||
fn into_diag_arg(self) -> rustc_errors::DiagArgValue {
|
||||
let kind = match self {
|
||||
Self::Empty => "empty",
|
||||
Self::RefValidFor => "ref_valid_for",
|
||||
@@ -129,8 +129,8 @@ impl IntoDiagnosticArg for PrefixKind {
|
||||
}
|
||||
}
|
||||
|
||||
impl IntoDiagnosticArg for SuffixKind {
|
||||
fn into_diagnostic_arg(self) -> rustc_errors::DiagArgValue {
|
||||
impl IntoDiagArg for SuffixKind {
|
||||
fn into_diag_arg(self) -> rustc_errors::DiagArgValue {
|
||||
let kind = match self {
|
||||
Self::Empty => "empty",
|
||||
Self::Continues => "continues",
|
||||
|
||||
Reference in New Issue
Block a user