Skip to content

Commit 3fda957

Browse files
committed
Remove out-of-date comments.
These refer to code that no longer exists.
1 parent 1936e44 commit 3fda957

File tree

1 file changed

+0
-16
lines changed
  • src/librustc_data_structures/obligation_forest

1 file changed

+0
-16
lines changed

src/librustc_data_structures/obligation_forest/mod.rs

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -61,14 +61,6 @@
6161
//! results. This is used by the `FulfillmentContext` to decide when it
6262
//! has reached a steady state.
6363
//!
64-
//! #### Snapshots
65-
//!
66-
//! The `ObligationForest` supports a limited form of snapshots; see
67-
//! `start_snapshot`, `commit_snapshot`, and `rollback_snapshot`. In
68-
//! particular, you can use a snapshot to roll back new root
69-
//! obligations. However, it is an error to attempt to
70-
//! `process_obligations` during a snapshot.
71-
//!
7264
//! ### Implementation details
7365
//!
7466
//! For the most part, comments specific to the implementation are in the
@@ -151,10 +143,6 @@ pub struct ObligationForest<O: ForestObligation> {
151143
/// At the end of processing, those nodes will be removed by a
152144
/// call to `compress`.
153145
///
154-
/// At all times we maintain the invariant that every node appears
155-
/// at a higher index than its parent. This is needed by the
156-
/// backtrace iterator (which uses `split_at`).
157-
///
158146
/// Ideally, this would be an `IndexVec<NodeIndex, Node<O>>`. But that is
159147
/// slower, because this vector is accessed so often that the
160148
/// `u32`-to-`usize` conversions required for accesses are significant.
@@ -288,8 +276,6 @@ impl<O: ForestObligation> ObligationForest<O> {
288276
}
289277

290278
/// Registers an obligation.
291-
///
292-
/// This CAN be done in a snapshot
293279
pub fn register_obligation(&mut self, obligation: O) {
294280
// Ignore errors here - there is no guarantee of success.
295281
let _ = self.register_obligation_at(obligation, None);
@@ -355,8 +341,6 @@ impl<O: ForestObligation> ObligationForest<O> {
355341
}
356342

357343
/// Converts all remaining obligations to the given error.
358-
///
359-
/// This cannot be done during a snapshot.
360344
pub fn to_errors<E: Clone>(&mut self, error: E) -> Vec<Error<O, E>> {
361345
let mut errors = vec![];
362346
for i in 0..self.nodes.len() {

0 commit comments

Comments
 (0)