mirror of https://codeberg.org/topola/topola.git
fix(autorouter/planar_reconfigurer): Differentiate search nodes also by length
This fixes 4x4_1206_led_matrix_breakout test.
This commit is contained in:
parent
88f8b3610d
commit
f2c67ed81d
|
|
@ -69,7 +69,9 @@ struct SccSearchNode {
|
||||||
|
|
||||||
impl Ord for SccSearchNode {
|
impl Ord for SccSearchNode {
|
||||||
fn cmp(&self, other: &Self) -> Ordering {
|
fn cmp(&self, other: &Self) -> Ordering {
|
||||||
self.curr_permutation.cmp(&other.curr_permutation)
|
self.curr_permutation
|
||||||
|
.cmp(&other.curr_permutation)
|
||||||
|
.then(self.length.cmp(&other.length))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -83,7 +85,7 @@ impl Eq for SccSearchNode {}
|
||||||
|
|
||||||
impl PartialEq for SccSearchNode {
|
impl PartialEq for SccSearchNode {
|
||||||
fn eq(&self, other: &Self) -> bool {
|
fn eq(&self, other: &Self) -> bool {
|
||||||
self.curr_permutation == other.curr_permutation
|
self.curr_permutation == other.curr_permutation && self.length == other.length
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue