diff options
| author | Nicholas Nethercote <nnethercote@mozilla.com> | 2019-09-20 12:53:22 +1000 |
|---|---|---|
| committer | Nicholas Nethercote <nnethercote@mozilla.com> | 2019-09-20 12:53:22 +1000 |
| commit | aa10abb2119f0740aac704a78d6eebd800ddb1da (patch) | |
| tree | 23c0d46b2b663bd95c2bb87c155b693f4f13c7b8 | |
| parent | 27c7c23840290fed94aef069b47169b26b7c3625 (diff) | |
| download | rust-aa10abb2119f0740aac704a78d6eebd800ddb1da.tar.gz rust-aa10abb2119f0740aac704a78d6eebd800ddb1da.zip | |
Rename a variable.
Because the meaning of this `index` variable is quite different to all the other `index` variables in this file.
| -rw-r--r-- | src/librustc_data_structures/obligation_forest/mod.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/librustc_data_structures/obligation_forest/mod.rs b/src/librustc_data_structures/obligation_forest/mod.rs index 2b7c44cdac3..1c7109fe500 100644 --- a/src/librustc_data_structures/obligation_forest/mod.rs +++ b/src/librustc_data_structures/obligation_forest/mod.rs @@ -507,8 +507,8 @@ impl<O: ForestObligation> ObligationForest<O> { let node = &self.nodes[index]; match node.state.get() { NodeState::OnDfsStack => { - let index = stack.iter().rposition(|&n| n == index).unwrap(); - processor.process_backedge(stack[index..].iter().map(GetObligation(&self.nodes)), + let rpos = stack.iter().rposition(|&n| n == index).unwrap(); + processor.process_backedge(stack[rpos..].iter().map(GetObligation(&self.nodes)), PhantomData); } NodeState::Success => { |
