#include <GenericNodes.h>
Inheritance diagram for Node:
Public Member Functions | |
Node (const sint32 newOpcode=-1, const uint32 newOffset=0, const Type newRType=Type()) | |
virtual | ~Node () |
sint32 | opcode () const |
uint32 | offset () const |
const Type & | rtype () const |
void | rtype (const Type &newRType) |
virtual bool | fold (DCUnit *unit, std::deque< Node * > &nodes)=0 |
virtual void | print_unk (Console &o, const uint32 isize) const =0 |
virtual void | print_asm (Console &o) const |
virtual void | print_mac (Console &o) const |
virtual void | print_bin (ODequeDataSource &o) const =0 |
void | fold_linenum (std::deque< Node * > &nodes) |
void | print_linenum_unk (Console &o, const uint32 isize) const |
void | print_linenum_asm (Console &o) const |
void | print_linenum_bin (ODequeDataSource &o) const |
Protected Member Functions | |
Node * | grab (std::deque< Node * > &nodes) |
Protected Attributes | |
sint32 | _opcode |
uint32 | _offset |
Type | _rtype |
Node * | linenum |
Definition at line 95 of file GenericNodes.h.
Node::Node | ( | const sint32 | newOpcode = -1 , |
|
const uint32 | newOffset = 0 , |
|||
const Type | newRType = Type() | |||
) | [inline] |
Definition at line 98 of file GenericNodes.h.
virtual Node::~Node | ( | ) | [inline, virtual] |
Definition at line 100 of file GenericNodes.h.
Implemented in DCCallPostfixNode, DCCallMutatorNode, DCCallNode, FuncMutatorNode, DCFuncNode, EndNode, IfNode, LoopScriptNode, LoopNode, LoopNextNode, UniOperatorNode, BinOperatorNode, PopVarNode, and PushVarNode.
void Node::fold_linenum | ( | std::deque< Node * > & | nodes | ) | [inline] |
Definition at line 184 of file GenericNodes.h.
References acceptOp(), linenum, offset(), and opcode().
Referenced by PopVarNode::fold(), BinOperatorNode::fold(), LoopNode::fold(), LoopScriptNode::fold(), EndNode::fold(), IfNode::fold(), FuncMutatorNode::fold(), and DCCallNode::fold().
Definition at line 136 of file GenericNodes.h.
References n.
Referenced by LoopNode::fold(), DCCallNode::fold(), BinNode::grab_l(), and ColNode::grab_p().
uint32 Node::offset | ( | ) | const [inline] |
sint32 Node::opcode | ( | ) | const [inline] |
Definition at line 102 of file GenericNodes.h.
References _opcode.
Referenced by FuncMutatorNode::a_initsize(), and fold_linenum().
void Node::print_asm | ( | Console & | o | ) | const [inline, virtual] |
Reimplemented in DCCallPostfixNode, DCCallMutatorNode, DCCallNode, FuncMutatorNode, DCFuncNode, EndNode, IfNode, LoopScriptNode, LoopNode, LoopNextNode, UniOperatorNode, BinOperatorNode, PopVarNode, and PushVarNode.
Definition at line 152 of file GenericNodes.h.
References _offset, _opcode, and PrintHelperNode::print_asm_header().
Referenced by PushVarNode::print_asm(), PopVarNode::print_asm(), BinOperatorNode::print_asm(), UniOperatorNode::print_asm(), LoopNode::print_asm(), EndNode::print_asm(), IfNode::print_asm(), FuncMutatorNode::print_asm(), DCCallNode::print_asm(), DCCallMutatorNode::print_asm(), DCCallPostfixNode::print_asm(), and print_linenum_asm().
virtual void Node::print_bin | ( | ODequeDataSource & | o | ) | const [pure virtual] |
Implemented in DCCallPostfixNode, DCCallMutatorNode, DCCallNode, FuncMutatorNode, DCFuncNode, EndNode, IfNode, LoopScriptNode, LoopNode, LoopNextNode, UniOperatorNode, BinOperatorNode, PopVarNode, and PushVarNode.
Referenced by PopVarNode::print_bin(), BinOperatorNode::print_bin(), UniOperatorNode::print_bin(), IfNode::print_bin(), DCCallNode::print_bin(), DCCallMutatorNode::print_bin(), and print_linenum_bin().
void Node::print_linenum_asm | ( | Console & | o | ) | const [inline] |
Definition at line 170 of file GenericNodes.h.
References linenum, print_asm(), and Console::Putchar().
Referenced by PopVarNode::print_asm(), BinOperatorNode::print_asm(), LoopNextNode::print_asm(), LoopNode::print_asm(), LoopScriptNode::print_asm(), EndNode::print_asm(), IfNode::print_asm(), FuncMutatorNode::print_asm(), and DCCallNode::print_asm().
void Node::print_linenum_bin | ( | ODequeDataSource & | o | ) | const [inline] |
Definition at line 179 of file GenericNodes.h.
References linenum, and print_bin().
Referenced by PopVarNode::print_bin(), BinOperatorNode::print_bin(), LoopNextNode::print_bin(), LoopNode::print_bin(), LoopScriptNode::print_bin(), EndNode::print_bin(), IfNode::print_bin(), FuncMutatorNode::print_bin(), and DCCallNode::print_bin().
Definition at line 162 of file GenericNodes.h.
References linenum, and print_unk().
Referenced by PopVarNode::print_unk(), BinOperatorNode::print_unk(), LoopNextNode::print_unk(), LoopNode::print_unk(), LoopScriptNode::print_unk(), EndNode::print_unk(), IfNode::print_unk(), FuncMutatorNode::print_unk(), and DCCallNode::print_unk().
void Node::print_mac | ( | Console & | o | ) | const [inline, virtual] |
Definition at line 157 of file GenericNodes.h.
References _offset, _opcode, and PrintHelperNode::print_mac_header().
Referenced by DCFuncNode::print_bin().
Implemented in DCCallPostfixNode, DCCallMutatorNode, DCCallNode, FuncMutatorNode, DCFuncNode, EndNode, IfNode, LoopScriptNode, LoopNode, LoopNextNode, UniOperatorNode, BinOperatorNode, PopVarNode, and PushVarNode.
Referenced by print_linenum_unk(), PopVarNode::print_unk(), BinOperatorNode::print_unk(), UniOperatorNode::print_unk(), IfNode::print_unk(), DCCallNode::print_unk(), and DCCallMutatorNode::print_unk().
void Node::rtype | ( | const Type & | newRType | ) | [inline] |
const Type& Node::rtype | ( | ) | const [inline] |
Definition at line 105 of file GenericNodes.h.
References _rtype.
Referenced by BinOperatorNode::BinOperatorNode(), DCCallMutatorNode::DCCallMutatorNode(), DCCallPostfixNode::DCCallPostfixNode(), PopVarNode::fold(), BinOperatorNode::fold(), DCCallNode::fold(), PopVarNode::PopVarNode(), BinOperatorNode::print_asm(), UniOperatorNode::print_asm(), LoopNextNode::print_asm(), LoopScriptNode::print_asm(), EndNode::print_asm(), IfNode::print_asm(), FuncMutatorNode::print_asm(), DCCallNode::print_asm(), DCCallMutatorNode::print_asm(), DCCallPostfixNode::print_asm(), BinOperatorNode::print_bin(), UniOperatorNode::print_bin(), LoopNextNode::print_bin(), LoopScriptNode::print_bin(), EndNode::print_bin(), IfNode::print_bin(), FuncMutatorNode::print_bin(), DCCallNode::print_bin(), DCCallMutatorNode::print_bin(), DCCallPostfixNode::print_bin(), DCCallNode::print_extern_unk(), BinOperatorNode::print_unk(), UniOperatorNode::print_unk(), LoopNextNode::print_unk(), LoopScriptNode::print_unk(), EndNode::print_unk(), IfNode::print_unk(), FuncMutatorNode::print_unk(), DCCallNode::print_unk(), DCCallMutatorNode::print_unk(), DCCallPostfixNode::print_unk(), PushVarNode::PushVarNode(), DCCallNode::setRetVal(), and UniOperatorNode::UniOperatorNode().
uint32 Node::_offset [protected] |
Definition at line 145 of file GenericNodes.h.
Referenced by offset(), EndNode::print_asm(), IfNode::print_asm(), print_asm(), EndNode::print_bin(), IfNode::print_bin(), FuncMutatorNode::print_bin(), and print_mac().
sint32 Node::_opcode [protected] |
Definition at line 142 of file GenericNodes.h.
Referenced by opcode(), print_asm(), and print_mac().
Type Node::_rtype [protected] |
Node* Node::linenum [protected] |
Definition at line 147 of file GenericNodes.h.
Referenced by fold_linenum(), print_linenum_asm(), print_linenum_bin(), and print_linenum_unk().