We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent da439d9 commit 02b3664Copy full SHA for 02b3664
compiler/rustc_hir_analysis/src/check/compare_impl_item.rs
@@ -648,6 +648,13 @@ pub(super) fn collect_return_position_impl_trait_in_trait_tys<'tcx>(
648
tcx.fn_sig(trait_m.def_id).subst(tcx, trait_to_placeholder_substs),
649
)
650
.fold_with(&mut collector);
651
+
652
+ debug_assert_ne!(
653
+ collector.types.len(),
654
+ 0,
655
+ "expect >1 RPITITs in call to `collect_return_position_impl_trait_in_trait_tys`"
656
+ );
657
658
let trait_sig = ocx.normalize(&norm_cause, param_env, unnormalized_trait_sig);
659
trait_sig.error_reported()?;
660
let trait_return_ty = trait_sig.output();
0 commit comments