diff options
Diffstat (limited to 'chain/src/default.rs')
-rw-r--r-- | chain/src/default.rs | 19 |
1 files changed, 17 insertions, 2 deletions
diff --git a/chain/src/default.rs b/chain/src/default.rs index 1e0eba2..11f0c93 100644 --- a/chain/src/default.rs +++ b/chain/src/default.rs @@ -633,6 +633,7 @@ impl Chain for DefaultChain { let mut new_label = *child_label; new_label.set_true_source(true_pavi); + // new_label.set_forest_source(pavi); output.extend( std::iter::repeat(new_label.into()) @@ -723,6 +724,20 @@ impl Chain for DefaultChain { continue; } + #[allow(clippy::single_match)] + match label.forest_source() { + PaVi::Parent(node, _, _) => match self.forest.vertex_label(node) { + Ok(Some(label)) => match label.label().end() { + Some(end) if end != pos => { + continue; + } + _ => {} + }, + _ => {} + }, + _ => {} + } + let virtual_node = self .atom .atom(non, t) @@ -911,7 +926,7 @@ impl Chain for DefaultChain { // First perform reduction. - let _ = self.forest.print_viz("forest before reduction.gv"); + // let _ = self.forest.print_viz("forest before reduction.gv"); // self.forest.reduction(root, pos, ter, &self.atom, true)?; @@ -1070,7 +1085,7 @@ impl Chain for DefaultChain { self.atom.print_virtual(); let _ = item::default::print_labels(&self.atom, &self.forest); - let _ = self.forest.print_viz("forest before extraction.gv"); + // let _ = self.forest.print_viz("forest before extraction.gv"); result = self.forest.extract(pos)?; |