We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 4137f3b + 9010708 commit 9fd2832Copy full SHA for 9fd2832
compiler/rustc_middle/src/mir/syntax.rs
@@ -395,7 +395,7 @@ pub enum StatementKind<'tcx> {
395
/// `PlaceMention(PLACE)`.
396
///
397
/// When executed at runtime, this computes the given place, but then discards
398
- /// it without doing a load. It is UB if the place is not pointing to live memory.
+ /// it without doing a load. `let _ = *ptr;` is fine even if the pointer is dangling.
399
PlaceMention(Box<Place<'tcx>>),
400
401
/// Encodes a user's type ascription. These need to be preserved
0 commit comments