* lib/monitor.rb (MonitorMixin::extend_object): should use
#__send__ instead of #send to avoid possible name conflict. [ruby-core:23907] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@23754 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
ab7baebb6d
commit
a910caecb8
@ -1,3 +1,9 @@
|
|||||||
|
Sat Jun 20 07:17:52 2009 Yukihiro Matsumoto <matz@ruby-lang.org>
|
||||||
|
|
||||||
|
* lib/monitor.rb (MonitorMixin::extend_object): should use
|
||||||
|
#__send__ instead of #send to avoid possible name conflict.
|
||||||
|
[ruby-core:23907]
|
||||||
|
|
||||||
Sat Jun 20 06:56:31 2009 Tadayoshi Funaba <tadf@dotrb.org>
|
Sat Jun 20 06:56:31 2009 Tadayoshi Funaba <tadf@dotrb.org>
|
||||||
|
|
||||||
* complex.c: edited rdoc.
|
* complex.c: edited rdoc.
|
||||||
|
@ -91,13 +91,13 @@ module MonitorMixin
|
|||||||
if timeout
|
if timeout
|
||||||
raise NotImplementedError, "timeout is not implemented yet"
|
raise NotImplementedError, "timeout is not implemented yet"
|
||||||
end
|
end
|
||||||
@monitor.send(:mon_check_owner)
|
@monitor.__send__(:mon_check_owner)
|
||||||
count = @monitor.send(:mon_exit_for_cond)
|
count = @monitor.__send__(:mon_exit_for_cond)
|
||||||
begin
|
begin
|
||||||
@cond.wait(@monitor.instance_variable_get("@mon_mutex"))
|
@cond.wait(@monitor.instance_variable_get("@mon_mutex"))
|
||||||
return true
|
return true
|
||||||
ensure
|
ensure
|
||||||
@monitor.send(:mon_enter_for_cond, count)
|
@monitor.__send__(:mon_enter_for_cond, count)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -114,12 +114,12 @@ module MonitorMixin
|
|||||||
end
|
end
|
||||||
|
|
||||||
def signal
|
def signal
|
||||||
@monitor.send(:mon_check_owner)
|
@monitor.__send__(:mon_check_owner)
|
||||||
@cond.signal
|
@cond.signal
|
||||||
end
|
end
|
||||||
|
|
||||||
def broadcast
|
def broadcast
|
||||||
@monitor.send(:mon_check_owner)
|
@monitor.__send__(:mon_check_owner)
|
||||||
@cond.broadcast
|
@cond.broadcast
|
||||||
end
|
end
|
||||||
|
|
||||||
@ -137,7 +137,7 @@ module MonitorMixin
|
|||||||
|
|
||||||
def self.extend_object(obj)
|
def self.extend_object(obj)
|
||||||
super(obj)
|
super(obj)
|
||||||
obj.send(:mon_initialize)
|
obj.__send__(:mon_initialize)
|
||||||
end
|
end
|
||||||
|
|
||||||
#
|
#
|
||||||
|
Loading…
x
Reference in New Issue
Block a user