pub trait NodeAssignmentMethod<T, S: Clone> {
// Required methods
fn get(&self, node: &Rc<T>) -> Option<S>;
fn set(&self, node: &Rc<T>, symbol: Option<S>);
fn delete(&self, node: &Rc<T>) -> bool;
fn has(&self, node: &Rc<T>) -> bool;
}Expand description
Defines access methods for the NodeAssignment structure,
used for attaching semantics to the syntactic tree,
where T is the node type, and S is the symbol type.
Required Methods§
fn get(&self, node: &Rc<T>) -> Option<S>
fn set(&self, node: &Rc<T>, symbol: Option<S>)
fn delete(&self, node: &Rc<T>) -> bool
fn has(&self, node: &Rc<T>) -> bool
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".