Two uses of context tree.

This commit is contained in:
Tom Alexander 2022-12-04 00:53:59 -05:00
parent fb8a31a88f
commit 396813c70a
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE
1 changed files with 6 additions and 1 deletions

View File

@ -9,6 +9,7 @@ use super::nom_context::ChainBehavior;
use super::nom_context::ContextElement;
use super::nom_context::ContextTree;
use super::nom_context::FailMatcherNode;
use super::nom_context::PreviousElementNode;
use super::text::bold_end;
use super::text::bold_start;
use super::text::line_break;
@ -77,7 +78,11 @@ where
}
ret.push(many_elem);
// TODO: make new context
current_context = current_context.with_additional_node(
ContextElement::PreviousElementNode(PreviousElementNode {
element: many_elem.into(),
}),
);
i = remaining;
}
}