Rollup merge of #108958 - clubby789:unbox-the-hir, r=compiler-errors

Remove box expressions from HIR

After #108516, `#[rustc_box]` is used at HIR->THIR lowering and this is no longer emitted, so it can be removed.

This is based on top of #108471 to help with conflicts, so 43490488ccacd1a822e9c621f5ed6fca99959a0b is the only relevant commit (sorry for all the duplicated pings!)

````@rustbot```` label +S-blocked
This commit is contained in:
Matthias Krüger 2023-03-17 08:42:37 +01:00 committed by GitHub
commit 13ff2d42cd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
27 changed files with 12 additions and 73 deletions

View file

@ -2944,9 +2944,6 @@ impl<'tcx> TypeErrCtxtExt<'tcx> for TypeErrCtxt<'_, '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");
}