Skip to content

Commit afbf6c8

Browse files
committed
s/in_index/input_index/
1 parent ef9ae85 commit afbf6c8

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/librustc_incremental/persist/preds/compress/dag_id.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,11 @@ pub struct DagId {
77
}
88

99
impl DagId {
10-
pub fn from_in_index(n: NodeIndex) -> Self {
10+
pub fn from_input_index(n: NodeIndex) -> Self {
1111
DagId { index: n.0 as u32 }
1212
}
1313

14-
pub fn as_in_index(&self) -> NodeIndex {
14+
pub fn as_input_index(&self) -> NodeIndex {
1515
NodeIndex(self.index as usize)
1616
}
1717
}

src/librustc_incremental/persist/preds/compress/mod.rs

+5-5
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ impl<'q, N, I, O> GraphReduce<'q, N, I, O>
8989
// correspond to the indices from the input graph
9090
for i in 0..in_graph.len_nodes() {
9191
let k = unify.new_key(());
92-
assert!(k == DagId::from_in_index(NodeIndex(i)));
92+
assert!(k == DagId::from_input_index(NodeIndex(i)));
9393
}
9494

9595
GraphReduce { in_graph, unify, is_input, is_output }
@@ -105,17 +105,17 @@ impl<'q, N, I, O> GraphReduce<'q, N, I, O>
105105
}
106106

107107
fn mark_cycle(&mut self, in_node1: NodeIndex, in_node2: NodeIndex) {
108-
let dag_id1 = DagId::from_in_index(in_node1);
109-
let dag_id2 = DagId::from_in_index(in_node2);
108+
let dag_id1 = DagId::from_input_index(in_node1);
109+
let dag_id2 = DagId::from_input_index(in_node2);
110110
self.unify.union(dag_id1, dag_id2);
111111
}
112112

113113
/// Convert a dag-id into its cycle head representative. This will
114114
/// be a no-op unless `in_node` participates in a cycle, in which
115115
/// case a distinct node *may* be returned.
116116
fn cycle_head(&mut self, in_node: NodeIndex) -> NodeIndex {
117-
let i = DagId::from_in_index(in_node);
118-
self.unify.find(i).as_in_index()
117+
let i = DagId::from_input_index(in_node);
118+
self.unify.find(i).as_input_index()
119119
}
120120

121121
#[cfg(test)]

0 commit comments

Comments
 (0)