pub enum Visit {
Children,
Parent,
}
Expand description
Visit strategy after having visited an AST node.
Some AST nodes have children – in enum’s variants, in some fields as nested in Vec
, etc.
Those nodes can be visited depending on the strategy you chose.
Variants§
Children
The visitor will go deeper in the AST by visiting all the children, if any. If no children are present or if having children doesn’t make sense for a specific part of the AST, this strategy will be ignored.
Parent
The visitor won’t visit children nor siblings and will go up.
Trait Implementations§
impl Copy for Visit
impl Eq for Visit
impl StructuralPartialEq for Visit
Auto Trait Implementations§
impl Freeze for Visit
impl RefUnwindSafe for Visit
impl Send for Visit
impl Sync for Visit
impl Unpin for Visit
impl UnwindSafe for Visit
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)