about summary refs log tree commit diff
path: root/compiler/rustc_trait_selection/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2025-07-11 05:27:32 +0000
committerbors <bors@rust-lang.org>2025-07-11 05:27:32 +0000
commit855e0fe46e68d94e9f6147531b75ac2d488c548e (patch)
treee7d73ebfdb909118cf6e79acac8a64a6f414f54b /compiler/rustc_trait_selection/src
parentcdac44e608c3df9a241e0a1b53b3f62af250dbf1 (diff)
parent25eb3829e5661ab85067188ca9e6586c29aed6e9 (diff)
downloadrust-855e0fe46e68d94e9f6147531b75ac2d488c548e.tar.gz
rust-855e0fe46e68d94e9f6147531b75ac2d488c548e.zip
Auto merge of #142911 - mejrs:unsized, r=compiler-errors
Remove support for dynamic allocas

Followup to rust-lang/rust#141811
Diffstat (limited to 'compiler/rustc_trait_selection/src')
-rw-r--r--compiler/rustc_trait_selection/src/error_reporting/traits/suggestions.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/compiler/rustc_trait_selection/src/error_reporting/traits/suggestions.rs b/compiler/rustc_trait_selection/src/error_reporting/traits/suggestions.rs
index 8c9eb41568f..bd1d29826e6 100644
--- a/compiler/rustc_trait_selection/src/error_reporting/traits/suggestions.rs
+++ b/compiler/rustc_trait_selection/src/error_reporting/traits/suggestions.rs
@@ -3719,6 +3719,12 @@ impl<'a, 'tcx> TypeErrCtxt<'a, 'tcx> {
                 );
                 suggest_remove_deref(err, &expr);
             }
+            ObligationCauseCode::UnsizedNonPlaceExpr(span) => {
+                err.span_note(
+                    span,
+                    "unsized values must be place expressions and cannot be put in temporaries",
+                );
+            }
         }
     }