Trait lang_util::node::NodeContentDisplay
source · pub trait NodeContentDisplay {
// Required methods
fn name() -> Option<&'static str>;
fn display_extra(&self, f: &mut Formatter<'_>) -> Result;
fn display_children(&self, level: usize, f: &mut Formatter<'_>) -> Result;
}
Expand description
Trait for displaying an AST node’s content
Required Methods§
sourcefn name() -> Option<&'static str>
fn name() -> Option<&'static str>
Name of the node
§Returns
None
if this node is just a transparent wrapper (and should not be displayed), otherwise
the name of the node type.
sourcefn display_extra(&self, f: &mut Formatter<'_>) -> Result
fn display_extra(&self, f: &mut Formatter<'_>) -> Result
Object Safety§
This trait is not object safe.