From: spooq Date: 2006-11-17T22:06:42+09:00 Subject: Re: #returning and #tap On 11/17/06, Trans wrote: > > spooq wrote: > > Actually, how about giving the proc a copy of the object, rather than > > the real deal? > > > > class Object > > def tap > > yield self.dup > > self > > end > > end > > "Do as if frozen". Perhaps #freeze could take a block? Nice. Sounds very reusable.