General

Profile

alanwu (Alan Wu)

  • Login: alanwu
  • Registered on: 10/28/2018
  • Last sign in: 10/21/2026

Issues

open closed Total
Assigned issues 4 33 37
Reported issues 5 53 58

Projects

Project Roles Registered on
Ruby Committer 03/19/2021

Activity

11/21/2026

03:33 AM Ruby Misc #22544: DevMeeting-2026-12-10
* [Bug #22562] Type confusion SEGV: Using `super` and `instance_exec` it is possible to run Array#first on an instance of Integer (alanwu)
* Matz attention needed to decide new rules for switching self then using `super`. Two options a...
alanwu (Alan Wu)
03:25 AM Ruby Bug #22562: Type confusion SEGV: Using `super` and `instance_exec` it is possible to run Array#first on an instance of Integer
Renaming ticket because during development I found cases that don't involve `bind_call`.
https://github.com/ruby/ruby/pull/20013
alanwu (Alan Wu)
03:18 AM Ruby Bug #22562: Type confusion SEGV: Using `super` and `instance_exec` it is possible to run Array#first on an instance of Integer
@matz To fix this bug, we'll need to amend how `self` is type-checked when `super` happens after switching `self` (through e.g. `instance_exec`, `eval`). I have found two options, please decide which one you would prefer so we can have a... alanwu (Alan Wu)
02:01 AM Ruby Bug #22616 (Closed): SystemStackError from `super` when refining a method from a module that appears twice in ancestry
```ruby
class C0; end; class C1 < C0; end
module M1; end
c0 = C0.new
c1 = C1.new.extend(M1)
module R1; refine(M1) { def m = super }; end
C0.prepend M1
p c1.singleton_class.ancestors # [#<singleton>, M1, C1, M1, C0, ...]
using R...
alanwu (Alan Wu)
12:26 AM Ruby Bug #22614 (Closed): Regressions: Adverse interactions between (unused) refinements and UnboundMethod#bind_call
```ruby
# a.rb
module M; end
class A < Array; include M; end
using(Module.new { refine(M) { def first = super } })
p A.instance_method(:first).bind_call(0x6f56)
# [BUG] Segmentation fault at 0x000000000000dead
__END__
Correct N...
alanwu (Alan Wu)
12:20 AM Ruby Feature #22613: iseq freeing after require/load without reference
Good idea to save memory.
Though, freeing at a certain program point by taking a ractor barrier is incorrect. That does not prevent you from freeing code that some other ractor is still running. Like trying to free JIT code, only the GC...
alanwu (Alan Wu)

11/20/2026

10:53 PM Ruby Bug #22612 (Open): False sharing of prepended singleton methods when singleton class is cloned

```ruby
class Foo
def bar = :from_class
end
mod = Module.new { def bar = [:mod, super] }
o = Foo.new
o.singleton_class.prepend(mod)
clone = o.clone
def o.bar = :original_only
p clone.bar # => [:mod, :original_only], shou...
alanwu (Alan Wu)

11/17/2026

05:00 PM Ruby Bug #22562 (Open): Type confusion SEGV: Using `super` and `instance_exec` it is possible to run Array#first on an instance of Integer
The following crashes 3.3.0 through current trunk (commit:caf4f279d1):
```ruby
module M
# fixnum: (0x6f56<<1)+1 = 0xdead
def first = 0x6f56.instance_exec { super }
end
M.instance_method(:first).bind_call([])
# <internal:array>...
alanwu (Alan Wu)

11/16/2026

09:35 PM Ruby Revision 4ed70f0c (git): ZJIT: Allow zero-capacity BitSet for empty FrameState::spilled_locals
We make a lot of empty BitSets for FrameState::spilled_locals and
previously allocated memory for the clear bits unnecessarily.
There is now one representation for the all-clear BitSet of any size.
alanwu (Alan Wu)
09:35 PM Ruby Revision e5170965 (git): ZJIT: Update HIR snapshots for instruction renumbering
alanwu (Alan Wu)

Also available in: Atom