summaryrefslogtreecommitdiff
path: root/node.c
diff options
context:
space:
mode:
Diffstat (limited to 'node.c')
-rw-r--r--node.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/node.c b/node.c
index 60e01caa31..2efcd6eba8 100644
--- a/node.c
+++ b/node.c
@@ -13,7 +13,6 @@
#include <stddef.h>
#include "node.h"
#include "rubyparser.h"
-#include "internal/parse.h"
#endif
#include "internal/variable.h"
@@ -301,8 +300,9 @@ rb_ast_t *
rb_ast_new(const rb_parser_config_t *config)
{
node_buffer_t *nb = rb_node_buffer_new(config);
- rb_ast_t *ast = config->ast_new(nb);
+ rb_ast_t *ast = (rb_ast_t *)config->calloc(1, sizeof(rb_ast_t));
ast->config = config;
+ ast->node_buffer = nb;
return ast;
}
#else