Skip to content

Commit 2b96cfb

Browse files
committed
add comments on remaining fields
1 parent c36707a commit 2b96cfb

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/librustc_mir/build/scope.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,15 @@ use rustc_const_eval::ConstInt;
100100
pub struct Scope<'tcx> {
101101
/// the scope-id within the scope_datas
102102
id: ScopeId,
103+
104+
/// the extent of this scope within source code; also stored in
105+
/// `ScopeAuxiliary`, but kept here for convenience
103106
extent: CodeExtent,
107+
108+
/// set of lvalues to drop when exiting this scope. This starts
109+
/// out empty but grows as variables are declared during the
110+
/// building process. This is a stack, so we always drop from the
111+
/// end of the vector (top of the stack) first.
104112
drops: Vec<DropData<'tcx>>,
105113

106114
/// A scope may only have one associated free, because:

0 commit comments

Comments
 (0)