feat(traverse): Introduce new accessor methods (#152)

This commit is contained in:
Santiago Carmuega 2022-07-16 19:31:27 -03:00 committed by GitHub
parent fbea30aafe
commit 33c6152f19
17 changed files with 507 additions and 238 deletions

View file

@ -273,7 +273,7 @@ impl<T> Deref for CborWrap<T> {
}
}
#[derive(Debug, Clone)]
#[derive(Debug, Clone, PartialEq, PartialOrd)]
pub struct TagWrap<I, const T: u64>(I);
impl<I, const T: u64> TagWrap<I, T> {
@ -309,6 +309,14 @@ where
}
}
impl<I, const T: u64> Deref for TagWrap<I, T> {
type Target = I;
fn deref(&self) -> &Self::Target {
&self.0
}
}
/// An empty map
///
/// don't ask me why, that's what the CDDL asks for.