Running into lifetime issues.
This commit is contained in:
parent
c8cf6a78a0
commit
7e0e776486
@ -25,3 +25,9 @@ pub trait Loopable {
|
||||
/// for each element of the array.
|
||||
fn get_loop_elements(&self) -> Vec<&dyn ContextElement>;
|
||||
}
|
||||
|
||||
impl PartialEq<dyn ContextElement> for dyn ContextElement {
|
||||
fn eq(&self, other: &dyn ContextElement) -> bool {
|
||||
todo!()
|
||||
}
|
||||
}
|
||||
|
@ -9,6 +9,7 @@ pub enum RenderError {
|
||||
TemplateNotFound(String),
|
||||
}
|
||||
|
||||
#[derive(PartialEq)]
|
||||
pub enum WalkError {
|
||||
CantWalk,
|
||||
}
|
||||
|
@ -225,7 +225,7 @@ impl<'a> DustRenderer<'a> {
|
||||
};
|
||||
}
|
||||
DustTag::DTHelperEquals(parameterized_block) => {
|
||||
let param_map: HashMap<&'a str, &'a RValue<'a>> = parameterized_block
|
||||
let param_map: HashMap<&str, &RValue<'a>> = parameterized_block
|
||||
.params
|
||||
.iter()
|
||||
.map(|pair: &KVPair<'a>| (pair.key, &pair.value))
|
||||
@ -245,6 +245,14 @@ impl<'a> DustRenderer<'a> {
|
||||
RValue::RVPath(path) => walk_path(breadcrumbs, &path.keys),
|
||||
},
|
||||
};
|
||||
// let x = WalkError::CantWalk;
|
||||
// let y = WalkError::CantWalk;
|
||||
// if x == y {
|
||||
// panic!("placeholder");
|
||||
// }
|
||||
// if left_side.unwrap() == right_side.unwrap() {
|
||||
// panic!("placeholder");
|
||||
// }
|
||||
}
|
||||
_ => (), // TODO: Implement the rest
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user