1
Fork 0

obligation cause: RepeatVec -> RepeatValueCopy

This commit is contained in:
lcnr 2022-03-31 12:50:53 +02:00
parent e730969b0d
commit d7cada1767
4 changed files with 11 additions and 8 deletions

View file

@ -1988,7 +1988,7 @@ impl<'a, 'tcx> InferCtxtExt<'tcx> for InferCtxt<'a, 'tcx> {
ObligationCauseCode::Coercion { source: _, target } => {
err.note(&format!("required by cast to type `{}`", self.ty_to_string(target)));
}
ObligationCauseCode::RepeatVec(is_const_fn) => {
ObligationCauseCode::RepeatElementCopy { is_const_fn } => {
err.note(
"the `Copy` trait is required because the repeated element will be copied",
);