ast_printer_->inc_indent();
}
- IndentedScope(AstPrinter* printer, const char* txt, AstNode* node = NULL)
+ IndentedScope(AstPrinter* printer, const char* txt)
: ast_printer_(printer) {
ast_printer_->PrintIndented(txt);
ast_printer_->Print("\n");
void AstPrinter::PrintIndentedVisit(const char* s, AstNode* node) {
- IndentedScope indent(this, s, node);
+ IndentedScope indent(this, s);
Visit(node);
}
void AstPrinter::VisitAssignment(Assignment* node) {
- IndentedScope indent(this, Token::Name(node->op()), node);
+ IndentedScope indent(this, Token::Name(node->op()));
Visit(node->target());
Visit(node->value());
}
void AstPrinter::VisitProperty(Property* node) {
- IndentedScope indent(this, "PROPERTY", node);
+ IndentedScope indent(this, "PROPERTY");
Visit(node->obj());
Literal* literal = node->key()->AsLiteral();
if (literal != NULL && literal->handle()->IsInternalizedString()) {
void AstPrinter::VisitBinaryOperation(BinaryOperation* node) {
- IndentedScope indent(this, Token::Name(node->op()), node);
+ IndentedScope indent(this, Token::Name(node->op()));
Visit(node->left());
Visit(node->right());
}
void AstPrinter::VisitCompareOperation(CompareOperation* node) {
- IndentedScope indent(this, Token::Name(node->op()), node);
+ IndentedScope indent(this, Token::Name(node->op()));
Visit(node->left());
Visit(node->right());
}