}
}
- wfcx.register_wf_obligation(
- ty_span,
- Some(WellFormedLoc::Ty(item_id)),
- item_ty.into(),
- );
+ wfcx.register_wf_obligation(ty_span, Some(WellFormedLoc::Ty(item_id)), item_ty.into());
if forbid_unsized {
wfcx.register_bound(
traits::ObligationCause::new(ty_span, wfcx.body_id, traits::WellFormed(None)),
// parameter includes another (e.g., `<T, U = T>`). In those cases, we can't
// be sure if it will error or not as user might always specify the other.
if !ty.needs_subst() {
- wfcx.register_wf_obligation(
- tcx.def_span(param.def_id),
- None,
- ty.into(),
- );
+ wfcx.register_wf_obligation(tcx.def_span(param.def_id), None, ty.into());
}
}
}
assert_eq!(predicates.predicates.len(), predicates.spans.len());
let wf_obligations =
iter::zip(&predicates.predicates, &predicates.spans).flat_map(|(&p, &sp)| {
- traits::wf::predicate_obligations(infcx, wfcx.param_env.without_const(), wfcx.body_id, p, sp)
+ traits::wf::predicate_obligations(
+ infcx,
+ wfcx.param_env.without_const(),
+ wfcx.body_id,
+ p,
+ sp,
+ )
});
let obligations: Vec<_> = wf_obligations.chain(default_obligations).collect();
);
}
- wfcx.register_wf_obligation(
- hir_decl.output.span(),
- None,
- sig.output().into(),
- );
+ wfcx.register_wf_obligation(hir_decl.output.span(), None, sig.output().into());
check_where_clauses(wfcx, span, def_id);
}
impl const IndexMut for <() as Index>::Output {
const C: <Self as Index>::Output = ();
type Assoc = <Self as Index>::Output;
- fn foo(&mut self, x: <Self as Index>::Output) -> <Self as Index>::Output where <Self as Index>::Output: {}
+ fn foo(&mut self, x: <Self as Index>::Output) -> <Self as Index>::Output
+ where <Self as Index>::Output:,
+ {}
}
const C: <() as Index>::Output = ();