Trait CanVisitSyntaxTree

Source
pub trait CanVisitSyntaxTree<V, E>
where V: SyntaxTreeVisitor<E>,
{ // Required method fn visit(&self, node: &mut V) -> Result<(), E>; }
Expand description

Provides the ability to apply a visitor.

§Type Parameters

  • V: The type of visitor to apply.
  • E: The type of error that can occur while visiting.

Required Methods§

Source

fn visit(&self, node: &mut V) -> Result<(), E>

Apply the specified visitor to the receiver.

§Parameters
  • visitor: The visitor to apply.
§Errors

An error if one occurs while visiting the receiver.

Implementations on Foreign Types§

Source§

impl<V, E> CanVisitSyntaxTree<V, E> for Node<'_>
where V: SyntaxTreeVisitor<E>,

Source§

fn visit(&self, visitor: &mut V) -> Result<(), E>

Implementors§