Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions Zend/zend_ast.c
Original file line number Diff line number Diff line change
Expand Up @@ -1871,7 +1871,7 @@ static ZEND_COLD void zend_ast_export_class_no_header(smart_str *str, zend_ast_d
smart_str_appends(str, " {\n");
zend_ast_export_stmt(str, decl->child[2], indent + 1);
zend_ast_export_indent(str, indent);
smart_str_appends(str, "}");
smart_str_appendc(str, '}');
}

static ZEND_COLD void zend_ast_export_attribute_group(smart_str *str, zend_ast *ast, int indent) {
Expand Down Expand Up @@ -1899,7 +1899,7 @@ static ZEND_COLD void zend_ast_export_attributes(smart_str *str, zend_ast *ast,
for (i = 0; i < list->children; i++) {
smart_str_appends(str, "#[");
zend_ast_export_attribute_group(str, list->child[i], indent);
smart_str_appends(str, "]");
smart_str_appendc(str, ']');

if (newlines) {
smart_str_appendc(str, '\n');
Expand Down Expand Up @@ -2060,7 +2060,7 @@ static ZEND_COLD void zend_ast_export_ex(smart_str *str, zend_ast *ast, int prio
case ZEND_AST_OP_ARRAY:
smart_str_appends(str, "Closure(");
smart_str_append(str, zend_ast_get_op_array(ast)->op_array->function_name);
smart_str_appends(str, ")");
smart_str_appendc(str, ')');
break;
case ZEND_AST_CONSTANT_CLASS:
smart_str_appendl(str, "__CLASS__", sizeof("__CLASS__")-1);
Expand Down Expand Up @@ -2427,9 +2427,9 @@ static ZEND_COLD void zend_ast_export_ex(smart_str *str, zend_ast *ast, int prio
case ZEND_AST_CALL: {
zend_ast *left = ast->child[0];
if (left->kind == ZEND_AST_ARROW_FUNC || left->kind == ZEND_AST_CLOSURE) {
smart_str_appends(str, "(");
smart_str_appendc(str, '(');
zend_ast_export_ns_name(str, left, 0, indent);
smart_str_appends(str, ")");
smart_str_appendc(str, ')');
} else {
zend_ast_export_ns_name(str, left, 0, indent);
}
Expand Down Expand Up @@ -2679,9 +2679,9 @@ static ZEND_COLD void zend_ast_export_ex(smart_str *str, zend_ast *ast, int prio
smart_str_appends(str, " {\n");
zend_ast_export_ex(str, ast->child[1], 0, indent + 1);
zend_ast_export_indent(str, indent);
smart_str_appends(str, "}");
smart_str_appendc(str, '}');
} else {
smart_str_appends(str, ";");
smart_str_appendc(str, ';');
}
break;
case ZEND_AST_TRAIT_PRECEDENCE:
Expand Down