From: "alexeymuranov (Alexey Muranov)" Date: 2012-07-16T05:10:58+09:00 Subject: [ruby-core:46498] [ruby-trunk - Feature #6721] Object#yield_self Issue #6721 has been updated by alexeymuranov (Alexey Muranov). drbrain (Eric Hodel) wrote: > Your current names are less clear than using a local variable. Using a local variable reveals your intentions very clearly: Well, using method chains with blocks is always less clear than using local variables. ---------------------------------------- Feature #6721: Object#yield_self https://bugs.ruby-lang.org/issues/6721#change-28134 Author: alexeymuranov (Alexey Muranov) Status: Open Priority: Normal Assignee: Category: Target version: =begin I think the following method is missing from Ruby: class Object def yield_self(*args) yield(self, *args) end end I do not know a good use case, but it looks very natural to me. It can be used in method chains. What do you think? Is there an alternative? =end -- http://bugs.ruby-lang.org/