ruby-concurrency / concurrent-ruby

Modern concurrency tools including agents, futures, promises, thread pools, supervisors, and more. Inspired by Erlang, Clojure, Scala, Go, Java, JavaScript, and classic concurrency patterns.
https://ruby-concurrency.github.io/concurrent-ruby/
Other
5.68k stars 418 forks source link

Fix setting AtomicReferenceImplementation on TruffleRuby #925

Closed eregon closed 2 years ago

eregon commented 2 years ago
$ ruby -ve 'p class C; alias_method :id, :object_id; end'
ruby 2.7.4p191 (2021-07-07 revision a21a3b7d23) [x86_64-linux]
C
$ chruby 3.0.2                                           
$ ruby -ve 'p class C; alias_method :id, :object_id; end'
ruby 3.0.2p107 (2021-07-07 revision 0db68f0233) [x86_64-linux]
:id

This is blocking to implement the change about alias_method;s return value in https://github.com/oracle/truffleruby/pull/2499. Could you make a bug fix release with this fix soon if possible?

cc @pitr-ch

eregon commented 2 years ago

For the anecdote, I noticed this originated from 877dc76fce60ef93d8e43637543eccec1703f0ce, which worked accidentally because include returns the receiver (still does in Ruby 3).

eregon commented 2 years ago

@pitr-ch or other concurrent-ruby maintainers, could you merge this?

jdantonio commented 2 years ago

@eregon I've given you write permissions. <3

eregon commented 2 years ago

Thank you!

It would be great to have a release including this when maintainers have some time. For now I made a patch in TruffleRuby (https://github.com/oracle/truffleruby/commit/5ea0bc28c67938922fb1ce1a7ec868958bfea55d), but it is quite messy, so a release of concurrent-ruby would be much better and the patch would not be needed/have no effect when using latest concurrent-ruby.

jdantonio commented 2 years ago

I've been out of the loop for a long time (I only lurk) so I'm hesitant to do a release myself. I'd be fine giving you and @chrisseaton access to RubyGems so that you can both make releases, but I think I'd be overstepping my bounds a bit right now. Hopefully @pitr-ch can jump in soon and give hi sthoughts.