7 #if !defined(_ElftosbAST_h_) 13 #include "smart_ptr.h" 14 #include "EvalContext.h" 51 : m_parent(other.m_parent)
52 , m_location(other.m_location)
59 virtual ASTNode *clone()
const = 0;
62 virtual std::string
nodeName()
const {
return "ASTNode"; }
65 virtual ASTNode *getParent()
const {
return m_parent; }
66 virtual void setParent(
ASTNode *newParent) { m_parent = newParent; }
71 virtual void printTree()
const { printTree(0); }
72 virtual void printTree(
int indent)
const;
77 virtual void setLocation(
token_loc_t &loc) { m_location = loc; }
79 virtual void setLocation(
ASTNode *loc) { setLocation(loc->getLocation()); }
82 virtual token_loc_t &getLocation() {
return m_location; }
83 virtual const token_loc_t &getLocation()
const {
return m_location; }
84 virtual int getFirstLine() {
return m_location.
m_firstLine; }
85 virtual int getLastLine() {
return m_location.m_lastLine; }
93 void printIndent(
int indent)
const;
110 typedef std::list<
ASTNode *> ast_list_t;
111 typedef ast_list_t::iterator iterator;
112 typedef ast_list_t::const_iterator const_iterator;
121 virtual std::string
nodeName()
const {
return "ListASTNode"; }
122 virtual void printTree(
int indent)
const;
126 virtual void appendNode(
ASTNode *node);
130 virtual unsigned nodeCount()
const {
return static_cast<unsigned>(m_list.size()); }
135 inline iterator begin() {
return m_list.begin(); }
136 inline iterator end() {
return m_list.end(); }
137 inline const_iterator begin()
const {
return m_list.begin(); }
138 inline const_iterator end()
const {
return m_list.end(); }
143 virtual void updateLocation();
162 inline ListASTNode *getOptions() {
return m_options; }
176 , m_constants(constants)
180 inline ListASTNode *getConstants() {
return m_constants; }
198 inline ListASTNode *getSources() {
return m_sources; }
215 , m_keyblobNumberExpr()
219 inline ListASTNode *getEntries() {
return m_entries; }
221 inline void setKeyblobNumberExpr(
ExprASTNode *numExpr) { m_keyblobNumberExpr = numExpr; }
222 inline ExprASTNode *getKeyblobNumberExpr() {
return m_keyblobNumberExpr; }
243 virtual std::string
nodeName()
const {
return "ExprASTNode"; }
250 int_size_t resultIntSize(int_size_t a, int_size_t b);
285 virtual std::string
nodeName()
const {
return "KeyblobEntryASTNode"; }
286 virtual void printTree(
int indent)
const;
288 void setFieldAssignments(
ListASTNode *fields) { m_fields = fields; }
289 ListASTNode *getFieldAssignments() {
return m_fields; }
304 virtual std::string
nodeName()
const {
return "CommandFileASTNode"; }
306 virtual void printTree(
int indent)
const;
308 inline void setBlocks(
ListASTNode *blocks) { m_blocks = blocks; }
309 inline void setOptions(
ListASTNode *options) { m_options = options; }
310 inline void setConstants(
ListASTNode *constants) { m_constants = constants; }
311 inline void setSources(
ListASTNode *sources) { m_sources = sources; }
312 inline void setSections(
ListASTNode *sections) { m_sections = sections; }
313 inline ListASTNode *getBlocks() {
return m_blocks; }
314 inline ListASTNode *getOptions() {
return m_options; }
315 inline ListASTNode *getConstants() {
return m_constants; }
316 inline ListASTNode *getSources() {
return m_sources; }
317 inline ListASTNode *getSections() {
return m_sections; }
341 virtual std::string
nodeName()
const {
return "IntConstExprASTNode"; }
343 virtual void printTree(
int indent)
const;
345 uint32_t getValue()
const {
return m_value; }
346 int_size_t getSize()
const {
return m_size; }
365 inline std::string *getVariableName() {
return m_variable; }
367 virtual std::string
nodeName()
const {
return "VariableExprASTNode"; }
368 virtual void printTree(
int indent)
const;
392 virtual std::string
nodeName()
const {
return "SymbolRefExprASTNode"; }
393 virtual void printTree(
int indent)
const;
415 virtual std::string
nodeName()
const {
return "NegativeExprASTNode"; }
416 virtual void printTree(
int indent)
const;
439 virtual std::string
nodeName()
const {
return "BooleanNotExprASTNode"; }
440 virtual void printTree(
int indent)
const;
457 , m_functionName(functionName)
458 , m_sourceFile(sourceFileName)
464 virtual std::string
nodeName()
const {
return "SourceFileFunctionASTNode"; }
465 virtual void printTree(
int indent)
const;
469 std::string *getFunctionName() {
return m_functionName; }
470 std::string *getSourceFile() {
return m_sourceFile; }
484 , m_constantName(constantName)
490 virtual std::string
nodeName()
const {
return "DefinedOperatorASTNode"; }
491 virtual void printTree(
int indent)
const;
495 std::string *getConstantName() {
return m_constantName; }
510 , m_constantName(constantName)
523 virtual std::string
nodeName()
const {
return "SizeofOperatorASTNode"; }
524 virtual void printTree(
int indent)
const;
528 std::string *getConstantName() {
return m_constantName; }
576 virtual std::string
nodeName()
const {
return "BinaryOpExprASTNode"; }
577 virtual void printTree(
int indent)
const;
583 operator_t getOp()
const {
return m_op; }
589 std::string getOperatorName()
const;
607 virtual std::string
nodeName()
const {
return "IntSizeExprASTNode"; }
608 virtual void printTree(
int indent)
const;
613 int_size_t getIntSize() {
return m_size; }
633 virtual std::string
nodeName()
const {
return "ExprConstASTNode"; }
634 virtual void printTree(
int indent)
const;
655 virtual std::string
nodeName()
const {
return "StringConstASTNode"; }
656 virtual void printTree(
int indent)
const;
658 std::string *getString() {
return m_value; }
677 virtual std::string
nodeName()
const {
return "BlobConstASTNode"; }
678 virtual void printTree(
int indent)
const;
680 Blob *getBlob() {
return m_blob; }
702 virtual std::string
nodeName()
const {
return "IVTConstASTNode"; }
703 virtual void printTree(
int indent)
const;
705 void setFieldAssignments(
ListASTNode *fields) { m_fields = fields; }
706 ListASTNode *getFieldAssignments() {
return m_fields; }
728 virtual std::string
nodeName()
const {
return "AssignmentASTNode"; }
729 virtual void printTree(
int indent)
const;
731 inline std::string *getIdent() {
return m_ident; }
732 inline ASTNode *getValue() {
return m_value; }
750 inline std::string *getName() {
return m_name; }
751 inline void setAttributes(
ListASTNode *attributes) { m_attributes = attributes; }
752 inline ListASTNode *getAttributes() {
return m_attributes; }
773 virtual std::string
nodeName()
const {
return "PathSourceDefASTNode"; }
774 virtual void printTree(
int indent)
const;
776 std::string *getPath() {
return m_path; }
796 virtual std::string
nodeName()
const {
return "ExternSourceDefASTNode"; }
797 virtual void printTree(
int indent)
const;
799 ExprASTNode *getSourceNumberExpr() {
return m_expr; }
815 : m_sectionExpr(section)
821 virtual std::string
nodeName()
const {
return "SectionContentsASTNode"; }
822 virtual void printTree(
int indent)
const;
824 inline void setSectionNumberExpr(
ExprASTNode *section) { m_sectionExpr = section; }
825 inline ExprASTNode *getSectionNumberExpr() {
return m_sectionExpr; }
826 inline void setOptions(
ListASTNode *options) { m_options = options; }
827 inline ListASTNode *getOptions() {
return m_options; }
841 , m_contents(contents)
848 virtual std::string
nodeName()
const {
return "DataSectionContentsASTNode"; }
849 virtual void printTree(
int indent)
const;
851 ASTNode *getContents() {
return m_contents; }
864 , m_statements(statements)
871 virtual std::string
nodeName()
const {
return "BootableSectionContentsASTNode"; }
872 virtual void printTree(
int indent)
const;
874 ListASTNode *getStatements() {
return m_statements; }
913 void setConditionExpr(
ExprASTNode *expr) { m_conditionExpr = expr; }
914 ExprASTNode *getConditionExpr() {
return m_conditionExpr; }
915 void setIfStatements(
ListASTNode *statements) { m_ifStatements = statements; }
916 ListASTNode *getIfStatements() {
return m_ifStatements; }
919 void setElseStatements(
ListASTNode *statements) { m_elseStatements = statements; }
920 ListASTNode *getElseStatements() {
return m_elseStatements; }
942 , m_modeExpr(modeExpr)
948 virtual std::string
nodeName()
const {
return "ModeStatementASTNode"; }
949 virtual void printTree(
int indent)
const;
951 inline void setModeExpr(
ExprASTNode *modeExpr) { m_modeExpr = modeExpr; }
952 inline ExprASTNode *getModeExpr() {
return m_modeExpr; }
965 , m_doEraseAll(
false)
966 , m_doEraseAllUnsecure(
false)
973 , m_doEraseAll(
false)
974 , m_doEraseAllUnsecure(
false)
976 , m_rangeExpr(rangeExpr)
982 virtual std::string
nodeName()
const {
return "EraseStatementASTNode"; }
983 virtual void printTree(
int indent)
const;
985 void setEraseAll(
bool doIt) { m_doEraseAll = doIt; }
986 bool getEraseAll()
const {
return m_doEraseAll; }
987 void setEraseAllUnsecure(
bool doIt) { m_doEraseAllUnsecure = doIt; }
988 bool getEraseAllUnsecure()
const {
return m_doEraseAllUnsecure; }
989 inline void setRangeExpr(
ASTNode *rangeExpr) { m_rangeExpr = rangeExpr; }
990 inline ASTNode *getRangeExpr() {
return m_rangeExpr; }
991 inline void setMemOption(
ASTNode *memOpt) { m_memOption = memOpt; }
992 inline ASTNode *getMemOption() {
return m_memOption; }
995 bool m_doEraseAllUnsecure;
1018 , m_type(messageType)
1019 , m_message(message)
1025 virtual std::string
nodeName()
const {
return "MessageStatementASTNode"; }
1026 virtual void printTree(
int indent)
const;
1028 inline message_type_t getType() {
return m_type; }
1029 inline std::string *getMessage() {
return m_message; }
1030 const char *getTypeName()
const;
1033 message_type_t m_type;
1062 virtual std::string
nodeName()
const {
return "LoadStatementASTNode"; }
1063 virtual void printTree(
int indent)
const;
1065 inline void setData(
ASTNode *data) { m_data = data; }
1066 inline ASTNode *getData() {
return m_data; }
1067 inline void setTarget(
ASTNode *target) { m_target = target; }
1068 inline ASTNode *getTarget() {
return m_target; }
1069 inline void setLoadOption(
ASTNode *memOpt) { m_loadOption = memOpt; }
1070 inline ASTNode *getLoadOption() {
return m_loadOption; }
1107 , m_stackPointer(sp)
1114 virtual std::string
nodeName()
const {
return "CallStatementASTNode"; }
1115 virtual void printTree(
int indent)
const;
1117 inline void setCallType(call_type_t callType) { m_type = callType; }
1118 inline call_type_t getCallType() {
return m_type; }
1119 inline void setTarget(
ASTNode *target) { m_target = target; }
1120 inline ASTNode *getTarget() {
return m_target; }
1121 inline void setArgument(
ASTNode *arg) { m_arg = arg; }
1122 inline ASTNode *getArgument() {
return m_arg; }
1123 inline void setIsHAB(
bool isHAB) { m_isHAB = isHAB; }
1124 inline bool isHAB()
const {
return m_isHAB; }
1125 inline void setStackPointer(
ASTNode *arg) { m_stackPointer = arg; }
1126 inline ASTNode *getStackPointer() {
return m_stackPointer; }
1151 virtual std::string
nodeName()
const {
return "ResetStatementASTNode"; }
1152 virtual void printTree(
int indent)
const;
1172 , m_rangeExpr(rangeExpr)
1178 virtual std::string
nodeName()
const {
return "MemEnableStatementASTNode"; }
1179 virtual void printTree(
int indent)
const;
1181 inline void setRangeExpr(
ASTNode *rangeExpr) { m_rangeExpr = rangeExpr; }
1182 inline ASTNode *getRangeExpr() {
return m_rangeExpr; }
1183 inline void setMemOption(
ASTNode *memOpt) { m_memOption = memOpt; }
1184 inline ASTNode *getMemOption() {
return m_memOption; }
1204 virtual std::string
nodeName()
const {
return "SourceASTNode"; }
1205 virtual void printTree(
int indent)
const;
1207 inline std::string *getSourceName() {
return m_name; }
1220 , m_sections(sections)
1227 , m_sections(sections)
1235 virtual std::string
nodeName()
const {
return "SectionMatchListASTNode"; }
1236 virtual void printTree(
int indent)
const;
1238 inline ListASTNode *getSections() {
return m_sections; }
1239 inline std::string *getSourceName() {
return m_source; }
1264 , m_action(kInclude)
1280 , m_action(kInclude)
1289 virtual std::string
nodeName()
const {
return "SectionASTNode"; }
1290 virtual void printTree(
int indent)
const;
1292 inline match_action_t getAction() {
return m_action; }
1293 inline std::string *getSectionName() {
return m_name; }
1294 inline std::string *getSourceName() {
return m_source; }
1296 match_action_t m_action;
1324 virtual std::string
nodeName()
const {
return "SymbolASTNode"; }
1325 virtual void printTree(
int indent)
const;
1327 inline void setSymbolName(std::string *symbol) { m_symbol = symbol; }
1328 inline std::string *getSymbolName() {
return m_symbol; }
1329 inline void setSource(std::string *source) { m_source = source; }
1330 inline std::string *getSource() {
return m_source; }
1359 virtual std::string
nodeName()
const {
return "AddressRangeASTNode"; }
1360 virtual void printTree(
int indent)
const;
1362 inline void setBegin(
ASTNode *begin) { m_begin = begin; }
1363 inline ASTNode *getBegin() {
return m_begin; }
1364 inline void setEnd(
ASTNode *end) { m_end = end; }
1365 inline ASTNode *getEnd() {
return m_end; }
1388 virtual std::string
nodeName()
const {
return "NaturalLocationASTNode"; }
1405 virtual std::string
nodeName()
const {
return "FromStatementASTNode"; }
1406 virtual void printTree(
int indent)
const;
1408 inline void setSourceName(std::string *source) { m_source = source; }
1409 inline std::string *getSourceName() {
return m_source; }
1410 inline void setStatements(
ListASTNode *statements) { m_statements = statements; }
1411 inline ListASTNode *getStatements() {
return m_statements; }
1426 , m_statements(statements)
1427 , m_keyblobNumberExpr()
1433 virtual std::string
nodeName()
const {
return "EncryptStatementASTNode"; }
1434 virtual void printTree(
int indent)
const;
1436 inline void setStatements(
ListASTNode *statements) { m_statements = statements; }
1437 inline ListASTNode *getStatements() {
return m_statements; }
1438 inline void setKeyblobNumberExpr(
ExprASTNode *numExpr) { m_keyblobNumberExpr = numExpr; }
1439 inline ExprASTNode *getKeyblobNumberExpr() {
return m_keyblobNumberExpr; }
1454 , m_statements(statements)
1455 , m_keyblobNumberExpr()
1461 virtual std::string
nodeName()
const {
return "KeywrapStatementASTNode"; }
1462 virtual void printTree(
int indent)
const;
1464 inline void setStatements(
ListASTNode *statements) { m_statements = statements; }
1465 inline ListASTNode *getStatements() {
return m_statements; }
1466 inline void setKeyblobNumberExpr(
ExprASTNode *numExpr) { m_keyblobNumberExpr = numExpr; }
1467 inline ExprASTNode *getKeyblobNumberExpr() {
return m_keyblobNumberExpr; }
1475 #endif // _ElftosbAST_h_ virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1433
ASTNode(const ASTNode &other)
Copy constructor.
Definition: ElftosbAST.h:50
Definition: ElftosbAST.h:741
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:463
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:414
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:439
Definition: ElftosbAST.h:256
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1324
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1235
call_type_t
Possible sub-types of call statements.
Definition: ElftosbAST.h:1084
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1432
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1323
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:633
Definition: ElftosbAST.h:329
Definition: ElftosbAST.h:1420
Definition: ElftosbAST.h:1193
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:284
smart_ptr< ASTNode > m_rangeExpr
Expression that evaluates to the config block address range.
Definition: ElftosbAST.h:1186
smart_ptr< ExprASTNode > m_modeExpr
Expression that evaluates to the new boot mode.
Definition: ElftosbAST.h:954
List of section matches for a particular source name.
Definition: ElftosbAST.h:1215
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:795
Definition: ElftosbAST.h:1374
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:947
Definition: ElftosbAST.h:882
Definition: ElftosbAST.h:209
smart_ptr< ExprASTNode > m_conditionExpr
Boolean expression.
Definition: ElftosbAST.h:922
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:871
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1460
Prints an informational messag to the user.
Definition: ElftosbAST.h:1008
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:490
smart_ptr< ListASTNode > m_elseStatements
Statements for the "else" part of the statements.
Definition: ElftosbAST.h:926
Node for a constant IVT structure as used by HAB4.
Definition: ElftosbAST.h:691
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:676
Returns true or false depending on whether a constant is defined.
Definition: ElftosbAST.h:479
Node for a keyblob entry.
Definition: ElftosbAST.h:274
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1025
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1288
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:438
int m_lastLine
Ending line of the token.
Definition: ElftosbAST.h:27
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:948
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:489
smart_ptr< std::string > m_constantName
Name of the constant.
Definition: ElftosbAST.h:531
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1061
Expression node for a symbol reference.
Definition: ElftosbAST.h:381
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1114
smart_ptr< IfStatementASTNode > m_nextIf
Link to next "else if". If this is non-NULL then m_elseStatements must be NULL and vice-versa...
Definition: ElftosbAST.h:925
smart_ptr< ASTNode > m_loadOption
Load option identifier.
Definition: ElftosbAST.h:1074
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:848
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1387
Definition: ElftosbAST.h:153
Definition: ElftosbAST.h:622
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:243
Definition: ElftosbAST.h:666
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1150
Definition: ElftosbAST.h:1394
smart_ptr< ListASTNode > m_fields
Fields are set through assignment statements.
Definition: ElftosbAST.h:292
Definition: ElftosbAST.h:900
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:728
Include sections matched by this node.
Definition: ElftosbAST.h:1257
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1358
smart_ptr< ExprASTNode > m_keyblobNumberExpr
Expression that evaluates to the keyblob instance number.
Definition: ElftosbAST.h:1442
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:870
Context for evaluating AST tree and expressions.
Definition: EvalContext.h:28
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:523
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:285
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1203
Performa a boolean inversion.
Definition: ElftosbAST.h:428
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1388
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1177
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:632
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1024
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:773
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1359
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:727
ASTNode()
Default constructor.
Definition: ElftosbAST.h:37
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1178
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:677
Simple, standard smart pointer class.
Definition: apps/elftosb/common/smart_ptr.h:18
smart_ptr< std::string > m_symbol
Required.
Definition: ElftosbAST.h:1332
Statement to print a message to the elftosb user.
Definition: ElftosbAST.h:1003
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:981
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:912
Prints a warning to the user.
Definition: ElftosbAST.h:1009
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:606
smart_ptr< ListASTNode > m_ifStatements
List of "if" section statements.
Definition: ElftosbAST.h:923
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1289
smart_ptr< ASTNode > m_memOption
Memory option identifier.
Definition: ElftosbAST.h:997
smart_ptr< SymbolASTNode > m_symbol
Symbol reference. If this is non-NULL then the constant name is used instead.
Definition: ElftosbAST.h:533
Definition: BootImage.h:13
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1404
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1151
Definition: ElftosbAST.h:1448
match_action_t
Possible actions for a section match list.
Definition: ElftosbAST.h:1255
Returns an integer that is the size in bytes of the operand.
Definition: ElftosbAST.h:505
smart_ptr< std::string > m_message
Message to report.
Definition: ElftosbAST.h:1034
smart_ptr< ASTNode > m_target
This becomes the IVT address in HAB mode.
Definition: ElftosbAST.h:1129
Token location in the source file.
Definition: ElftosbAST.h:24
bool m_isHAB
Stack pointer node for "jump sp" command.
Definition: ElftosbAST.h:1132
ASTNode * m_parent
Pointer to parent node of this object. May be NULL.
Definition: ElftosbAST.h:89
virtual ExprASTNode * reduce(EvalContext &context)
Evaluate the expression and produce a result node to replace this one.
Definition: ElftosbAST.h:249
Definition: ElftosbAST.h:859
smart_ptr< std::string > m_constantName
Name of the constant.
Definition: ElftosbAST.h:497
AST node for a section glob.
Definition: ElftosbAST.h:1251
AST node for a call statement.
Definition: ElftosbAST.h:1080
Statement to insert a ROM_ERASE_CMD command.
Definition: ElftosbAST.h:960
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1405
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:121
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:220
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:415
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:305
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:367
smart_ptr< ListASTNode > m_fields
Fields of the IVT are set through assignment statements.
Definition: ElftosbAST.h:709
Node representing a raw binary section definition.
Definition: ElftosbAST.h:836
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:654
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:199
Definition: ElftosbAST.h:784
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:120
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:575
Definition: IVTDataSource.h:91
Root node for the entire file.
Definition: ElftosbAST.h:298
Negates an expression.
Definition: ElftosbAST.h:595
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:847
virtual PathSourceDefASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:772
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1204
Definition: ElftosbAST.h:355
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:702
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1062
token_loc_t m_location
Location of this node in the source file.
Definition: ElftosbAST.h:90
smart_ptr< ASTNode > m_rangeExpr
Expression that evaluates to the erase address range.
Definition: ElftosbAST.h:996
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1113
Definition: ElftosbAST.h:807
_message_type
Definition: ElftosbAST.h:1006
smart_ptr< ASTNode > m_memOption
Memory option identifier.
Definition: ElftosbAST.h:1187
ast_list_t m_list
Ordered list of child nodes.
Definition: ElftosbAST.h:147
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:701
smart_ptr< ExprASTNode > m_keyblobNumberExpr
Expression that evaluates to the keyblob instance number.
Definition: ElftosbAST.h:1470
Negates an expression.
Definition: ElftosbAST.h:404
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:522
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:366
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:341
Statement to insert a ROM_MEM_ENABLE_CMD command.
Definition: ElftosbAST.h:1160
Calls a built-in function with a source as the parameter.
Definition: ElftosbAST.h:452
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:181
ASTNode(ASTNode *parent)
Constructor taking a parent node.
Definition: ElftosbAST.h:43
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:342
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:820
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:655
Definition: ElftosbAST.h:715
Abstract base class for all expression AST nodes.
Definition: ElftosbAST.h:231
Definition: ElftosbAST.h:1339
Statement to insert a ROM_MODE_CMD command.
Definition: ElftosbAST.h:932
smart_ptr< ExprASTNode > m_keyblobNumberExpr
Expression that evaluates to the keyblob instance number.
Definition: ElftosbAST.h:225
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:576
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:607
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:62
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:982
Manages a binary object of arbitrary length.
Definition: apps/elftosb/common/Blob.h:18
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:304
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:796
AST node for a load statement.
Definition: ElftosbAST.h:1040
Definition: ElftosbAST.h:189
AST node that contains other AST nodes.
Definition: ElftosbAST.h:107
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:392
virtual unsigned nodeCount() const
Returns the number of nodes in this list.
Definition: ElftosbAST.h:130
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:464
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:821
Statement to insert a ROM_RESET_CMD command.
Definition: ElftosbAST.h:1138
smart_ptr< std::string > m_source
Optional, may be NULL;.
Definition: ElftosbAST.h:1333
Definition: ElftosbAST.h:761
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:163
virtual std::string nodeName() const
Returns the name of the object's class.
Definition: ElftosbAST.h:1461
Definition: ElftosbAST.h:171
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:391
Definition: ElftosbAST.h:644
The base class for all AST node classes.
Definition: ElftosbAST.h:33
Definition: ElftosbAST.h:539
virtual ~ASTNode()
Destructor.
Definition: ElftosbAST.h:57
virtual ASTNode * clone() const
Returns an exact duplicate of this object.
Definition: ElftosbAST.h:1234
Definition: ElftosbAST.h:1304
int m_firstLine
Starting line of the token.
Definition: ElftosbAST.h:26