Omg lifetimes errors.
This commit is contained in:
parent
dff528da32
commit
83881e55b5
@ -19,6 +19,11 @@ impl<'r> ContextTree<'r> {
|
||||
let new_list = self.tree.push_front(data);
|
||||
ContextTree { tree: new_list }
|
||||
}
|
||||
|
||||
pub fn check_fail_matcher<'s>(&'r self, i: &'s str) -> IResult<&'s str, &'s str, VerboseError<&'s str>> {
|
||||
// todo
|
||||
todo!()
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Debug, Clone)]
|
||||
@ -43,7 +48,7 @@ pub enum ChainBehavior<'r> {
|
||||
IgnoreParent(Option<&'r Matcher>),
|
||||
}
|
||||
|
||||
impl std::fmt::Debug for ChainBehavior {
|
||||
impl<'r> std::fmt::Debug for ChainBehavior<'r> {
|
||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||
let mut formatter = f.debug_struct("ChainBehavior");
|
||||
// match self {
|
||||
|
@ -151,7 +151,7 @@ fn recognize_link_end(input: &str) -> Res<&str, &str> {
|
||||
recognize(link_end)(input)
|
||||
}
|
||||
|
||||
fn flat_link<'s, 'r, C>(context: Context<'r>, i: &'s str) -> Res<&'s str, Link<'s>> {
|
||||
fn flat_link<'s, 'r>(context: Context<'r>, i: &'s str) -> Res<&'s str, Link<'s>> {
|
||||
let new_context =
|
||||
context.with_additional_node(ContextElement::FailMatcherNode(FailMatcherNode {
|
||||
fail_matcher: ChainBehavior::AndParent(Some(&recognize_link_end)),
|
||||
|
Loading…
x
Reference in New Issue
Block a user