Trait seax_util::compiler_tools::ast::ASTNode
[−]
[src]
pub trait ASTNode { fn compile<'a>(&'a self, state: &'a SymTable<'a>) -> CompileResult; fn print_level(&self, level: usize) -> String; fn prettyprint(&self) -> String { ... } }
Trait for AST nodes.
Required Methods
fn compile<'a>(&'a self, state: &'a SymTable<'a>) -> CompileResult
Compile this node to a list of SVM expressions
fn print_level(&self, level: usize) -> String
Pretty-print this node at the desired indent level
Provided Methods
fn prettyprint(&self) -> String
Pretty-print this node to a String.
This should start with this node indented zero spaces, and recursively
walk the tree downward, increasing the indentation level by INDENT
every step.