diff --git a/ChangeLog b/ChangeLog index ce282e25b8..47ef672fd3 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +Sat Jun 11 23:07:32 2016 NAKAMURA Usaku + + * lib/forwardable.rb (_delegator_method): get rid of a warning which + causes test failures introduced at r55376. + Sat Jun 11 18:37:58 2016 Marcus Stollsteimer * ext/json/lib/*.rb: Removed some comments. Because these are unnecessary diff --git a/lib/forwardable.rb b/lib/forwardable.rb index fce560db81..aa45d41a31 100644 --- a/lib/forwardable.rb +++ b/lib/forwardable.rb @@ -202,7 +202,9 @@ module Forwardable else iseq.to_a.dig(-1, 1, 1, :mid) == method.to_sym end - method = "__send__ :#{method}," + method_call = "__send__(:#{method}, *args, &block)" + else + method_call = "#{method}(*args, &block)" end line_no = __LINE__+1; str = "#{<<-"begin;"}\n#{<<-"end;"}" @@ -211,7 +213,7 @@ module Forwardable def #{ali}(*args, &block) begin #{accessor} - end.#{method} *args, &block + end.#{method_call} end end end;