Rollup merge of #81636 - LingMan:slice_not_vec, r=petrochenkov
Directly use `Option<&[T]>` instead of converting from `Option<&Vec<T>>` later on ```@rustbot``` modify labels +C-cleanup +T-compiler
This commit is contained in:
commit
86e23cc9f1
1 changed files with 2 additions and 2 deletions
|
@ -2415,7 +2415,7 @@ impl<'a, 'tcx> LifetimeContext<'a, 'tcx> {
|
||||||
_ => break,
|
_ => break,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break Some(e);
|
break Some(&e[..]);
|
||||||
}
|
}
|
||||||
Elide::Forbid => break None,
|
Elide::Forbid => break None,
|
||||||
};
|
};
|
||||||
|
@ -2445,7 +2445,7 @@ impl<'a, 'tcx> LifetimeContext<'a, 'tcx> {
|
||||||
lifetime_refs.len(),
|
lifetime_refs.len(),
|
||||||
&lifetime_names,
|
&lifetime_names,
|
||||||
lifetime_spans,
|
lifetime_spans,
|
||||||
error.map(|p| &p[..]).unwrap_or(&[]),
|
error.unwrap_or(&[]),
|
||||||
);
|
);
|
||||||
err.emit();
|
err.emit();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue