Fix lifetime issue.

This commit is contained in:
Tom Alexander
2023-07-14 18:04:01 -04:00
parent 4966b02b79
commit b9a7c3f7f3
3 changed files with 9 additions and 9 deletions

View File

@@ -50,7 +50,7 @@ pub fn radio_link<'r, 's>(context: Context<'r, 's>, input: &'s str) -> Res<&'s s
#[tracing::instrument(ret, level = "debug")]
pub fn rematch_target<'x, 'r, 's>(
context: Context<'r, 's>,
target: &'x Vec<Object<'s>>,
target: &'x Vec<Object<'x>>,
input: &'s str,
) -> Res<&'s str, Vec<Object<'s>>> {
let mut remaining = input;
@@ -104,9 +104,9 @@ fn radio_target_end<'r, 's>(context: Context<'r, 's>, input: &'s str) -> Res<&'s
alt((tag("<"), tag(">"), line_ending))(input)
}
pub trait RematchObject {
pub trait RematchObject<'x> {
fn rematch_object<'r, 's>(
&self,
&'x self,
context: Context<'r, 's>,
input: &'s str,
) -> Res<&'s str, Object<'s>>;