@@ -406,13 +406,13 @@ fn resolve_struct_error<'sess, 'a>(resolver: &'sess Resolver,
406406 err
407407 }
408408 ResolutionError :: BindingShadowsSomethingUnacceptable ( what_binding, name, binding) => {
409- let ( shadows_what, article ) = ( binding. descr ( ) , binding . article ( ) ) ;
409+ let shadows_what = binding. descr ( ) ;
410410 let mut err = struct_span_err ! ( resolver. session, span, E0530 , "{}s cannot shadow {}s" ,
411411 what_binding, shadows_what) ;
412412 err. span_label ( span, format ! ( "cannot be named the same as {} {}" ,
413- article, shadows_what) ) ;
413+ binding . article( ) , shadows_what) ) ;
414414 let participle = if binding. is_import ( ) { "imported" } else { "defined" } ;
415- let msg = format ! ( "{} {} `{}` is {} here" , article , shadows_what, name, participle) ;
415+ let msg = format ! ( "the {} `{}` is {} here" , shadows_what, name, participle) ;
416416 err. span_label ( binding. span , msg) ;
417417 err
418418 }
@@ -4722,11 +4722,11 @@ impl<'a, 'crateloader: 'a> Resolver<'a, 'crateloader> {
47224722 `{ident}` to disambiguate", ident = ident) )
47234723 }
47244724 if b. is_extern_crate ( ) && self . session . rust_2018 ( ) {
4725- help_msgs. push ( format ! ( "use `::{ident}` to refer to the {thing} unambiguously" ,
4725+ help_msgs. push ( format ! ( "use `::{ident}` to refer to this {thing} unambiguously" ,
47264726 ident = ident, thing = b. descr( ) ) )
47274727 }
47284728 if misc == AmbiguityErrorMisc :: SuggestSelf {
4729- help_msgs. push ( format ! ( "use `self::{ident}` to refer to the {thing} unambiguously" ,
4729+ help_msgs. push ( format ! ( "use `self::{ident}` to refer to this {thing} unambiguously" ,
47304730 ident = ident, thing = b. descr( ) ) )
47314731 }
47324732
0 commit comments