@@ -2,7 +2,7 @@ use std::borrow::Cow;
22use std:: iter;
33
44use rustc_data_structures:: fx:: FxIndexSet ;
5- use rustc_errors:: { Applicability , E0050 , E0053 , struct_span_code_err} ;
5+ use rustc_errors:: { Applicability , E0805 , struct_span_code_err} ;
66use rustc_hir:: def_id:: { DefId , LocalDefId } ;
77use rustc_hir:: { self as hir, FnSig , HirId , ItemKind } ;
88use rustc_infer:: infer:: { self , InferCtxt , TyCtxtInferExt } ;
@@ -182,7 +182,7 @@ fn compare_number_of_method_arguments<'tcx>(
182182 let mut err = struct_span_code_err ! (
183183 tcx. dcx( ) ,
184184 impl_span,
185- E0050 , // FIXME(jdonszelmann): new error code
185+ E0805 ,
186186 "`{external_impl_name}` has {} but #[{eii_name}] requires it to have {}" ,
187187 potentially_plural_count( external_impl_number_args, "parameter" ) ,
188188 declaration_number_args
@@ -279,7 +279,6 @@ pub(crate) fn compare_eii_function_types<'tcx>(
279279 if let Err ( terr) = result {
280280 debug ! ( ?external_impl_sig, ?declaration_sig, ?terr, "sub_types failed" ) ;
281281
282- // TODO: nice error
283282 let emitted = report_eii_mismatch (
284283 infcx,
285284 cause,
@@ -330,7 +329,7 @@ fn report_eii_mismatch<'tcx>(
330329 let mut diag = struct_span_code_err ! (
331330 tcx. dcx( ) ,
332331 impl_err_span,
333- E0053 , // TODO: new error code
332+ E0805 ,
334333 "function `{}` has a type that is incompatible with the declaration of `#[{eii_name}]`" ,
335334 external_impl_name
336335 ) ;
0 commit comments