Move some test-only code to test files
This also relaxes the bounds on some structs and moves them to the impl block instead.
This commit is contained in:
parent
5c6d3bf389
commit
620ecc01a2
8 changed files with 85 additions and 78 deletions
|
@ -1,5 +1,13 @@
|
|||
use super::*;
|
||||
|
||||
impl<T: Eq + Hash> TransitiveRelation<T> {
|
||||
/// A "best" parent in some sense. See `parents` and
|
||||
/// `postdom_upper_bound` for more details.
|
||||
fn postdom_parent(&self, a: &T) -> Option<&T> {
|
||||
self.mutual_immediate_postdominator(self.parents(a))
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn test_one_step() {
|
||||
let mut relation = TransitiveRelation::default();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue