The following code produces a memory leak: ```ruby p(foo: 1) ``` It comes from the allocation in `compile.c`: ```c struct rb_callinfo_kwarg *kw_arg = rb_xmalloc_mul_add(len, sizeof(VALUE), sizeof(struct rb_ca...ibylich (Ilya Bylich)
As @nobu mentioned the following code gives no warnings (in verbose mode): ```ruby class A def foo; end alias foo foo; def foo; end end ``` but if we stop increment `alias_count` on `alias foo foo` the warning appears (...ibylich (Ilya Bylich)
The following code produces a memory leak: ```ruby class A 1.upto(Float::INFINITY) do |i| define_method(:"foo_#{i}") {} alias :"foo_#{i}" :"foo_#{i}" remove_method :"foo_#{i}" end end ``` It is very arti...ibylich (Ilya Bylich)
`p->lex.paren_nest` is equal to 1 after the following code: ```ruby self.[]= foo ``` `paren_nest` is used to differentiate `...` for ranges/forwarded arguments, and so `./miniruby -we 'foo.[]= bar, ...'` gives no `... at EOL, sho...ibylich (Ilya Bylich)
First of all, thanks a lot for your work. This is a huge (and incredibly valuable) addition to Ruby. I have your branch built locally and I played a lot with it during last few days. I've got a few questions: 1. Multiple ractors us...ibylich (Ilya Bylich)
Thanks for looking into this issue. > Do you think that will work for your purposes? Not really. I'm working on the 3d party parser and I was thinking about whether I need to backport these errors. If I'd need it in some other proj...ibylich (Ilya Bylich)
`compile.c` has a few places where it raises `SyntaxError`. Because of that `ruby -c`, Ripper and `RubyVM::AbstractSyntaxTree` don't catch them: ```sh > ruby -vce 'class X; break; end' ruby 2.7.1p83 (2020-03-31 revision a0c7c23c9c) ...ibylich (Ilya Bylich)