Browse Source

Add more comments.

lmfao
ticki 8 years ago
parent
commit
2df67b38b9
3 changed files with 3 additions and 1 deletions
  1. 1 1
      src/bk/lv.rs
  2. 1 0
      src/fail.rs
  3. 1 0
      src/lazy_init.rs

+ 1 - 1
src/bk/lv.rs

@@ -177,7 +177,7 @@ impl Iterator for LevelIter {
         if self.lv <= self.to {
             let ret = self.n;
 
-            // Increment the counter.
+            // Increment the level counter.
             self.lv = ret + 1;
 
             Some(Level(ret))

+ 1 - 0
src/fail.rs

@@ -36,6 +36,7 @@ pub fn oom() -> ! {
         if let Some(handler) = THREAD_OOM_HANDLER.with(|x| x.get()) {
             log!(DEBUG, "Calling the local OOM handler.");
 
+            // Duh! Obviously, we run the handler.
             handler();
         }
     }

+ 1 - 0
src/lazy_init.rs

@@ -45,6 +45,7 @@ impl<F: FnMut() -> T, T> LazyInit<F, T> {
             State::Uninitialized(ref mut f) => inner = f(),
         }
 
+        // Put the intialized value into the state.
         self.state = State::Initialized(inner);
 
         if let State::Initialized(ref mut x) = self.state {