Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
NullPointerException when using refinement including multiple modules and calling super #4237
Provide at least:
Also tested with 126.96.36.199 on Windows, same issue.
module R1 def *(v) [v, v] end end module R2 def *(v) [self, super] end end module P refine Symbol do include R1 include R2 end end using P p(:a * 1)
On ruby, prints
referenced this issue
Jan 31, 2019
Here are the Sequel specs that fail with NullPointerException on JRuby if the guards are removed from the top of the file:
There are some other refinement related failures on JRuby that I added guards for at the same time, but may be a different refinement issue. All 4 specs in this block still fail on JRuby 188.8.131.52 if the guard is removed:
Here's the related commit to add the guards:
I probably should have added links to the refinements themselves:
This is still not fixed on master, but it's not a bug in refinements.
Calls of the form
Running it without JIT works fine:
This will be fixed before 9.2.7 since behavior differs between interpreter and JIT.