Bug #19164
Updated by byroot (Jean Boussier) about 2 years ago
The following snippet showcase the bug. It passes on 3.1 and older, but fails on 3.2.0 ```ruby klass = Class.new klass.prepend(Module.new) klass.new.freeze klass.define_method(:bar) klass.class_eval do define_method(:bar) {} # works klass.remove_method(:bar) remove_method(:bar) # raise FrozenError end ``` Bisecting with this script points me to [e7b1ff984fde859a7778dec564731eb79392406f](https://github.com/ruby/ruby/commit/e7b1ff984fde859a7778dec564731eb79392406f), which suggest some part of the codebase might be misusing some user flags. I have a patch that fix this script but I doubt it's the right fix, I'll be working with @jemmai and @tenderlovemaking to find a proper fix. I'm opening this ticket to make sure it's addressed before the 3.2.0 final release.