General

Profile

shugo (Shugo Maeda)

  • Login: shugo
  • Registered on: 05/08/2008
  • Last sign in: 10/08/2026

Issues

open closed Total
Assigned issues 3 159 162
Reported issues 3 95 98

Projects

Project Roles Registered on
Ruby Committer, Infrastructure team 05/28/2008

Activity

10/10/2026

06:09 AM Ruby Feature #22309: Allow super in a module method to work if method was called by refinement method super
Thank you. I've confirmed that the leak is gone and that crefs with the same refinements now share iclasses, and I've approved https://github.com/ruby/ruby/pull/18910. shugo (Shugo Maeda)

10/09/2026

05:19 AM Ruby Feature #22309: Allow super in a module method to work if method was called by refinement method super
Sorry for the confusing wording. By "the other refinements" I meant the other refinements in the chain copied from the caller's cref, which `vm_search_normal_superclass` skips since d3774085aa. The refinements in scope at the `super` cal... shugo (Shugo Maeda)

10/07/2026

08:15 AM Ruby Feature #22392 (Rejected): Allow refinements to define && and ||
Thank you for the discussion at the developer meeting.
At the meeting, mame suggested an alternative: `lhs && rhs` as `lhs.&&() { rhs }`, which I had rejected myself before proposing this.
Anyway, I understand that it is difficult to...
shugo (Shugo Maeda)
06:52 AM Ruby Feature #22309: Allow super in a module method to work if method was called by refinement method super
One addition: since the cache is a Hash, refinements and their iclasses would be retained even after they are no longer needed. Making both the key and the value weak would avoid this; maybe `ObjectSpace::WeakMap` in weakmap.c could be u... shugo (Shugo Maeda)
03:52 AM Ruby Feature #22309: Allow super in a module method to work if method was called by refinement method super
I have approved https://github.com/ruby/ruby/pull/18910, but there is one thing I am concerned about.
The cache entries are keyed by the refinement iclass of each cref and never removed, so each `using` scope or `Proc#refined` copy that...
shugo (Shugo Maeda)

10/02/2026

12:35 PM Ruby Feature #22392: Allow refinements to define && and ||
alanwu (Alan Wu) wrote in #note-6:
> BTW, the cost analysis to non-users is incomplete in the PoC.
You're right that the analysis is incomplete.
As you say, a parse-time switch would be ideal, but I cannot think of a way to do that ...
shugo (Shugo Maeda)
02:28 AM Ruby Misc #22394: DevMeeting-2026-10-07
* [Feature #22392] Allow refinements to define && and || (shugo)
* I propose to allow `&&` and `||` to be defined in refinements, so that DSLs can write `where { name == "x" && age > 20 }` instead of `where { (name == "x") & (age > 20...
shugo (Shugo Maeda)

10/01/2026

07:53 AM Ruby Feature #22392: Allow refinements to define && and ||
alanwu (Alan Wu) wrote in #note-1:
> Please no. Changing non-method call operations to be method calls has disastrous time and space cost for everyone involved, JIT or not. If accepted, this would be yet another case of refinement makin...
shugo (Shugo Maeda)

09/30/2026

03:18 PM Ruby Revision 891973a9 (git): Keep a Ractor::Port pinned while Ractor#monitor copies it
ractor_monitor() copied *rp after an allocation that can run a
compacting GC, and used rp again after taking the ractor lock. The port
is embedded and the argument is dead once the pointer is taken, so
nothing kept the port in place.
S...
shugo (Shugo Maeda)
03:18 PM Ruby Revision 4c28391b (git): Keep a Monitor pinned while Monitor#enter blocks on its mutex
monitor_enter0() writes the owner and count after do_mutex_lock(),
which may block with the GVL released. The monitor was stored only in
a stack struct field that nothing read, which the compiler may drop, so
nothing was guaranteed to k...
shugo (Shugo Maeda)

Also available in: Atom