pub trait Visitable {
// Required method
fn visit<V>(&mut self, v: &mut V) -> Result<(), V::Error>
where V: Visitor;
}
Expand description
Visitable trait for [solang_parser::pt
] types.
All [solang_parser::pt
] types, such as [Statement], should implement the Visitable trait
that accepts a trait Visitor implementation, which has various callback handles for Solidity
Parse Tree nodes.
We want to take a &mut self
to be able to implement some advanced features in the future such
as modifying the Parse Tree before formatting it.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.