diff options
author | John Hawthorn <[email protected]> | 2024-11-20 23:06:34 -0800 |
---|---|---|
committer | John Hawthorn <[email protected]> | 2024-11-22 19:25:01 -0800 |
commit | a8ebc596d6c4df190df269668dc0168e96fff0fb (patch) | |
tree | 0de410a24a018ef28143ade928257e21b71206fd | |
parent | b4d13fac3dd5420475aa1e14fdad8137da7e3ee0 (diff) |
Free parse result under -c
Notes
Notes:
Merged: https://github.com/ruby/ruby/pull/12148
-rw-r--r-- | ruby.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -2566,7 +2566,10 @@ process_options(int argc, char **argv, ruby_cmdline_options_t *opt) if (dump & DUMP_BIT(syntax)) { printf("Syntax OK\n"); dump &= ~DUMP_BIT(syntax); - if (!dump) return Qtrue; + if (!dump) { + dispose_result(); + return Qtrue; + } } if (dump & DUMP_BIT(parsetree)) { |