about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorNiko Matsakis <niko@alum.mit.edu>2016-03-23 05:18:49 -0400
committerNiko Matsakis <niko@alum.mit.edu>2016-03-23 16:42:54 -0400
commit2b96cfb14375def79676a969ded1b00a44aa74c4 (patch)
treeac95c34a93c23c5b7115ba64082f335ab4ad467c /src
parentc36707a284be6b57990d6f5a2f84bb16655cfb81 (diff)
downloadrust-2b96cfb14375def79676a969ded1b00a44aa74c4.tar.gz
rust-2b96cfb14375def79676a969ded1b00a44aa74c4.zip
add comments on remaining fields
Diffstat (limited to 'src')
-rw-r--r--src/librustc_mir/build/scope.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/librustc_mir/build/scope.rs b/src/librustc_mir/build/scope.rs
index 00d517cc255..cc9a4c4e714 100644
--- a/src/librustc_mir/build/scope.rs
+++ b/src/librustc_mir/build/scope.rs
@@ -100,7 +100,15 @@ use rustc_const_eval::ConstInt;
 pub struct Scope<'tcx> {
     /// the scope-id within the scope_datas
     id: ScopeId,
+
+    /// the extent of this scope within source code; also stored in
+    /// `ScopeAuxiliary`, but kept here for convenience
     extent: CodeExtent,
+
+    /// set of lvalues to drop when exiting this scope. This starts
+    /// out empty but grows as variables are declared during the
+    /// building process. This is a stack, so we always drop from the
+    /// end of the vector (top of the stack) first.
     drops: Vec<DropData<'tcx>>,
 
     /// A scope may only have one associated free, because: