diff options
author | Tuowen Zhao <ztuowen@gmail.com> | 2016-09-23 16:30:09 -0600 |
---|---|---|
committer | Tuowen Zhao <ztuowen@gmail.com> | 2016-09-23 16:30:09 -0600 |
commit | 2f96d12dd05213276875d56fec361ff99ec9bd76 (patch) | |
tree | bd3a03c166198f75d529994b35870caf59be58da /lib/chillcg/include/code_gen/CG_chillRepr.h | |
parent | 699861922d5349ffa98b518f34016b2be2ca368d (diff) | |
download | chill-2f96d12dd05213276875d56fec361ff99ec9bd76.tar.gz chill-2f96d12dd05213276875d56fec361ff99ec9bd76.tar.bz2 chill-2f96d12dd05213276875d56fec361ff99ec9bd76.zip |
staging
Diffstat (limited to 'lib/chillcg/include/code_gen/CG_chillRepr.h')
-rwxr-xr-x | lib/chillcg/include/code_gen/CG_chillRepr.h | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/lib/chillcg/include/code_gen/CG_chillRepr.h b/lib/chillcg/include/code_gen/CG_chillRepr.h index 4a0510f..bcc267f 100755 --- a/lib/chillcg/include/code_gen/CG_chillRepr.h +++ b/lib/chillcg/include/code_gen/CG_chillRepr.h @@ -26,7 +26,7 @@ namespace omega { char *type() const { return strdup("chill"); }; // - std::vector<chillAST_node *> chillnodes; // TODO make private + std::vector<chillAST_Node *> chillnodes; // TODO make private void printChillNodes() const { for (int i = 0; i < chillnodes.size(); i++) { chillnodes[i]->print(); @@ -35,15 +35,15 @@ namespace omega { fflush(stdout); }; - CG_chillRepr(std::vector<chillAST_node *> cnodes) { + CG_chillRepr(std::vector<chillAST_Node *> cnodes) { chillnodes = cnodes; } - CG_chillRepr(chillAST_node *chillast) { + CG_chillRepr(chillAST_Node *chillast) { stmtclassname = strdup(chillast->getTypeString()); //fprintf(stderr, "made new chillRepr of class %s\n", stmtclassname); - if (chillast->asttype == CHILLAST_NODETYPE_COMPOUNDSTMT) { - std::vector<chillAST_node *> children = chillast->getChildren(); + if (chillast->getType() == CHILLAST_NODE_COMPOUNDSTMT) { + std::vector<chillAST_Node *> children = chillast->getChildren(); int numchildren = children.size(); for (int i = 0; i < numchildren; i++) { chillnodes.push_back(children[i]); @@ -54,11 +54,11 @@ namespace omega { } } - void addStatement(chillAST_node *s) { chillnodes.push_back(s); }; + void addStatement(chillAST_Node *s) { chillnodes.push_back(s); }; - std::vector<chillAST_node *> getChillCode() const { return chillnodes; }; + std::vector<chillAST_Node *> getChillCode() const { return chillnodes; }; - chillAST_node *GetCode(); + chillAST_Node *GetCode(); ~CG_chillRepr(); |