Skip to content

Commit

Permalink
Fix BasicObject cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
albus522 committed Aug 13, 2024
1 parent 7dfae62 commit e1a20c3
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/delayed/message_sending.rb
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
module Delayed
class DelayProxy < BasicObject
undef_method :==
undef_method :equal?
# What additional methods exist on BasicObject has changed over time
(::Object.instance_methods - [:__id__, :__send__, :instance_eval, :instance_exec]).each do |method|
undef_method method
end

# Let DelayProxy raise exceptions.
define_method(:raise, ::Object.instance_method(:raise))
Expand Down

0 comments on commit e1a20c3

Please sign in to comment.