From: "jhawthorn (John Hawthorn) via ruby-core" Date: 2026-11-12T01:02:02+00:00 Subject: [ruby-core:127428] [Ruby Bug#22535] Release mode segfault due to half-initialized error in singleton_method Issue #22535 has been updated by jhawthorn (John Hawthorn). Backport changed from 3.3: UNKNOWN, 3.4: UNKNOWN, 4.0: UNKNOWN to 3.3: DONTNEED, 3.4: REQUIRED, 4.0: REQUIRED 4.0: https://github.com/ruby/ruby/pull/19848 3.4: https://github.com/ruby/ruby/pull/19849 ---------------------------------------- Bug #22535: Release mode segfault due to half-initialized error in singleton_method https://bugs.ruby-lang.org/issues/22535#change-119874 * Author: tekknolagi (Maxwell Bernstein) * Status: Closed * Backport: 3.3: DONTNEED, 3.4: REQUIRED, 4.0: REQUIRED ---------------------------------------- This causes a segfault seemingly only in release mode: name = "never_interned_#{rand(10**12)}" begin Object.new.singleton_method(name) rescue NameError => e STDERR.puts "rescued #{e.class}; e.name.class = #{e.name.class}" STDERR.puts e.message # segfaults here (rb_sym_to_s on ID2SYM(0)) end -- https://bugs.ruby-lang.org/ ______________________________________________ ruby-core mailing list -- ruby-core@ml.ruby-lang.org To unsubscribe send an email to ruby-core-leave@ml.ruby-lang.org ruby-core info -- https://ml.ruby-lang.org/mailman3/lists/ruby-core.ml.ruby-lang.org/