pub struct Node<'a> {
pub obj: Expr<'a>,
pub start: usize,
pub end: usize,
pub parent: Option<NodeID>,
pub id_target: Option<Rc<str>>,
pub attrs: HashMap<String, HashMap<&'a str, &'a str>>,
}
Expand description
A wrapper around an Expr
which stores important metadata.
Fields§
§obj: Expr<'a>
The actual AST node that this Node holds.
start: usize
§end: usize
§parent: Option<NodeID>
§id_target: Option<Rc<str>>
Whether this node can be targeted (e.g. by a link), and what that target is.
attrs: HashMap<String, HashMap<&'a str, &'a str>>
Any additional attributes attached to the node Typically from Affiliated Keywords.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Node<'a>
impl<'a> RefUnwindSafe for Node<'a>
impl<'a> !Send for Node<'a>
impl<'a> !Sync for Node<'a>
impl<'a> Unpin for Node<'a>
impl<'a> UnwindSafe for Node<'a>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more