Skip to content

Commit b44e51c

Browse files
committed
Touch up a comment on LocalDecl::internal
1 parent 0727ade commit b44e51c

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

src/librustc/mir/mod.rs

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -411,14 +411,20 @@ pub struct LocalDecl<'tcx> {
411411
/// True if this corresponds to a user-declared local variable.
412412
pub is_user_variable: bool,
413413

414-
/// True if this is an internal local.
414+
/// True if this is an internal local
415+
///
415416
/// These locals are not based on types in the source code and are only used
416417
/// for drop flags at the moment.
417-
/// The generator transformation will sanity check the locals which are live across
418-
/// a suspension point against the type components of the generator which
419-
/// type checking knows are live across a suspension point.
420-
/// We need to flag drop flags to avoid triggering this check as they are introduced
418+
///
419+
/// The generator transformation will sanity check the locals which are live
420+
/// across a suspension point against the type components of the generator
421+
/// which type checking knows are live across a suspension point. We need to
422+
/// flag drop flags to avoid triggering this check as they are introduced
421423
/// after typeck.
424+
///
425+
/// This should be sound because the drop flags are fully algebraic, and
426+
/// therefore don't affect the OIBIT or outlives properties of the
427+
/// generator.
422428
pub internal: bool,
423429

424430
/// Type of this local.

0 commit comments

Comments
 (0)