@@ -38,7 +38,7 @@ pub enum DiagArgValue {
3838 Str ( Cow < ' static , str > ) ,
3939 // This gets converted to a `FluentNumber`, which is an `f64`. An `i32`
4040 // safely fits in an `f64`. Any integers bigger than that will be converted
41- // to strings in `into_diagnostic_arg ` and stored using the `Str` variant.
41+ // to strings in `into_diag_arg ` and stored using the `Str` variant.
4242 Number ( i32 ) ,
4343 StrListSepByAnd ( Vec < Cow < ' static , str > > ) ,
4444}
@@ -148,12 +148,12 @@ where
148148/// Implemented as a custom trait rather than `From` so that it is implemented on the type being
149149/// converted rather than on `DiagArgValue`, which enables types from other `rustc_*` crates to
150150/// implement this.
151- pub trait IntoDiagnosticArg {
152- fn into_diagnostic_arg ( self ) -> DiagArgValue ;
151+ pub trait IntoDiagArg {
152+ fn into_diag_arg ( self ) -> DiagArgValue ;
153153}
154154
155- impl IntoDiagnosticArg for DiagArgValue {
156- fn into_diagnostic_arg ( self ) -> DiagArgValue {
155+ impl IntoDiagArg for DiagArgValue {
156+ fn into_diag_arg ( self ) -> DiagArgValue {
157157 self
158158 }
159159}
@@ -419,8 +419,8 @@ impl DiagInner {
419419 self . children . push ( sub) ;
420420 }
421421
422- pub ( crate ) fn arg ( & mut self , name : impl Into < DiagArgName > , arg : impl IntoDiagnosticArg ) {
423- self . args . insert ( name. into ( ) , arg. into_diagnostic_arg ( ) ) ;
422+ pub ( crate ) fn arg ( & mut self , name : impl Into < DiagArgName > , arg : impl IntoDiagArg ) {
423+ self . args . insert ( name. into ( ) , arg. into_diag_arg ( ) ) ;
424424 }
425425
426426 /// Fields used for Hash, and PartialEq trait.
@@ -1243,7 +1243,7 @@ impl<'a, G: EmissionGuarantee> Diag<'a, G> {
12431243 pub fn arg(
12441244 & mut self ,
12451245 name: impl Into <DiagArgName >,
1246- arg: impl IntoDiagnosticArg ,
1246+ arg: impl IntoDiagArg ,
12471247 ) -> & mut Self {
12481248 self . deref_mut( ) . arg( name, arg) ;
12491249 self
0 commit comments