Require a box expression's type to be Sized
This commit is contained in:
parent
ba83b39d4e
commit
b8fff95961
4 changed files with 7 additions and 3 deletions
|
@ -2072,6 +2072,9 @@ impl<'a, 'tcx> InferCtxtExt<'tcx> for InferCtxt<'a, 'tcx> {
|
|||
ObligationCauseCode::SizedYieldType => {
|
||||
err.note("the yield type of a generator must have a statically known size");
|
||||
}
|
||||
ObligationCauseCode::SizedBoxType => {
|
||||
err.note("the type of a box expression must have a statically known size");
|
||||
}
|
||||
ObligationCauseCode::AssignmentLhsSized => {
|
||||
err.note("the left-hand-side of an assignment must have a statically known size");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue