pub(super) trait TypeErrCtxtExt<'a, 'tcx> {
// Required methods
fn apply_do_not_recommend(
&self,
obligation: &mut PredicateObligation<'tcx>,
) -> bool;
fn emit_specialized_closure_kind_error(
&self,
obligation: &PredicateObligation<'tcx>,
trait_ref: PolyTraitRef<'tcx>,
) -> Option<ErrorGuaranteed>;
fn fn_arg_obligation(
&self,
obligation: &PredicateObligation<'tcx>,
) -> Result<(), ErrorGuaranteed>;
fn try_conversion_context(
&self,
obligation: &PredicateObligation<'tcx>,
trait_ref: TraitRef<'tcx>,
err: &mut Diag<'_>,
) -> bool;
fn report_const_param_not_wf(
&self,
ty: Ty<'tcx>,
obligation: &PredicateObligation<'tcx>,
) -> Diag<'a>;
}Required Methods§
fn apply_do_not_recommend( &self, obligation: &mut PredicateObligation<'tcx>, ) -> bool
fn emit_specialized_closure_kind_error( &self, obligation: &PredicateObligation<'tcx>, trait_ref: PolyTraitRef<'tcx>, ) -> Option<ErrorGuaranteed>
fn fn_arg_obligation( &self, obligation: &PredicateObligation<'tcx>, ) -> Result<(), ErrorGuaranteed>
sourcefn try_conversion_context(
&self,
obligation: &PredicateObligation<'tcx>,
trait_ref: TraitRef<'tcx>,
err: &mut Diag<'_>,
) -> bool
fn try_conversion_context( &self, obligation: &PredicateObligation<'tcx>, trait_ref: TraitRef<'tcx>, err: &mut Diag<'_>, ) -> bool
When the E of the resulting Result<T, E> in an expression foo().bar().baz()?,
identify those method chain sub-expressions that could or could not have been annotated
with ?.