Commit 60146462 authored by Kevin Modzelewski's avatar Kevin Modzelewski

Rename expr->body

parent f1817d4f
......@@ -355,7 +355,7 @@ AST_ExceptHandler* read_excepthandler(BufferedReader* reader) {
AST_Exec* read_exec(BufferedReader* reader) {
AST_Exec* rtn = new AST_Exec();
rtn->expr = readASTExpr(reader);
rtn->body = readASTExpr(reader);
rtn->col_offset = readColOffset(reader);
rtn->globals = readASTExpr(reader);
rtn->lineno = reader->readULL();
......
......@@ -440,14 +440,6 @@ struct expr_dispatcher {
return ptr;
}
ResultPtr read(pypa::AstSetComp& l) {
AST_SetComp* ptr = new AST_SetComp();
location(ptr, l);
readVector(ptr->generators, l.generators);
ptr->elt = readItem(l.element);
return ptr;
}
ResultPtr read(pypa::AstName& a) {
AST_Name* ptr = new AST_Name();
location(ptr, a);
......
......@@ -450,8 +450,8 @@ void AST_Exec::accept(ASTVisitor* v) {
if (skip)
return;
if (expr)
expr->accept(v);
if (body)
body->accept(v);
}
void AST_Exec::accept_stmt(StmtVisitor* v) {
......@@ -1261,7 +1261,7 @@ bool PrintVisitor::visit_excepthandler(AST_ExceptHandler* node) {
bool PrintVisitor::visit_exec(AST_Exec* node) {
printf("exec ");
node->expr->accept(this);
node->body->accept(this);
if (node->globals) {
printf(" in ");
node->globals->accept(this);
......
......@@ -437,7 +437,7 @@ public:
class AST_Exec : public AST_stmt {
public:
AST_expr* expr;
AST_expr* body;
AST_expr* globals;
AST_expr* locals;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment