mirror of
https://github.com/ruby/ruby.git
synced 2025-08-27 06:56:13 +02:00
parse.y: Remove dispose_string
I think that recycling the delimiter string objects doesn't pay its complexity. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61682 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
380c84ea26
commit
ec01271cae
3 changed files with 0 additions and 21 deletions
9
parse.y
9
parse.y
|
@ -6123,14 +6123,6 @@ parser_regx_options(struct parser_params *parser)
|
|||
return options | RE_OPTION_ENCODING(kcode);
|
||||
}
|
||||
|
||||
static void
|
||||
dispose_string(struct parser_params *parser, VALUE str)
|
||||
{
|
||||
rb_ast_delete_mark_object(parser->ast, str);
|
||||
rb_str_free(str);
|
||||
rb_gc_force_recycle(str);
|
||||
}
|
||||
|
||||
static int
|
||||
parser_tokadd_mbchar(struct parser_params *parser, int c)
|
||||
{
|
||||
|
@ -6907,7 +6899,6 @@ parser_here_document(struct parser_params *parser, rb_strterm_heredoc_t *here)
|
|||
}
|
||||
if (nextc() == -1) {
|
||||
if (str) {
|
||||
dispose_string(parser, str);
|
||||
str = 0;
|
||||
}
|
||||
goto error;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue