aboutsummaryrefslogtreecommitdiffstats
path: root/parse.y
diff options
context:
space:
mode:
authormame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-11-09 01:32:11 +0000
committermame <mame@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2017-11-09 01:32:11 +0000
commitf09ad1dc5de28dd71cc92fd2de35f85a786ca112 (patch)
tree3a4f5ff73ef4b3fb3d81d4fa3fd28ff09dd9c50e /parse.y
parent3ba9e6b639afaf4c88145d56c9bd6746af16cfb7 (diff)
downloadruby-f09ad1dc5de28dd71cc92fd2de35f85a786ca112.tar.gz
use `rb_ast_dispose` instead of `rb_ast_free`
`rb_ast_dispose` calls `rb_gc_writebarrier_remember`. Unless we call it, the marked objects may not be GC'ed until `rb_ast_t` is GC'ed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60722 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y2
1 files changed, 1 insertions, 1 deletions
diff --git a/parse.y b/parse.y
index d9b3e2da03..658f64d035 100644
--- a/parse.y
+++ b/parse.y
@@ -12109,7 +12109,7 @@ ripper_parse0(VALUE parser_v)
parser_prepare(parser);
parser->ast = rb_ast_new();
ripper_yyparse((void*)parser);
- rb_ast_free(parser->ast);
+ rb_ast_dispose(parser->ast);
parser->ast = 0;
return parser->result;
}