ruby-changes:55500
From: git <ko1@a...>
Date: Wed, 24 Apr 2019 00:40:35 +0900 (JST)
Subject: [ruby-changes:55500] git:9629f4c051 (trunk): * 2019-04-24
git 2019-04-24 00:40:29 +0900 (Wed, 24 Apr 2019) New Revision: 9629f4c051 https://git.ruby-lang.org/ruby.git/commit/?id=3D9629f4c051 Log: * 2019-04-24 Modified files: version.h= Index: lib/drb/observer.rb =================================================================== --- lib/drb/observer.rb (revision 9628) +++ lib/drb/observer.rb (revision 9629) @@ -6,16 +6,17 @@ module DRb https://github.com/ruby/ruby/blob/trunk/lib/drb/observer.rb#L6 def notify_observers(*arg) if defined? @observer_state and @observer_state - if defined? @observer_peers - for i in @observer_peers.dup - begin - i.update(*arg) - rescue - delete_observer(i) - end - end - end - @observer_state = false + if defined? @observer_peers + @observer_peers.delete_if do |k, v| + begin + k.send(v, *arg) + false + rescue + true + end + end + end + @observer_state = false end end end Index: ChangeLog =================================================================== --- ChangeLog (revision 9628) +++ ChangeLog (revision 9629) @@ -1,3 +1,8 @@ https://github.com/ruby/ruby/blob/trunk/ChangeLog#L1 +Tue Nov 29 22:45:30 2005 Masatoshi SEKI <m_seki@m...> + + * lib/drb/observer.rb (notify_observers): follow change of observer.rb. + fixed: [ruby-core:6796] + Mon Nov 28 20:24:22 2005 Tanaka Akira <akr@m...> * lib/pp.rb (PP::PPMethods#object_address_group): adjust address format. -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/