Florian Groß
5/2/2005 6:33:00 AM
Eric Mahurin wrote:
> What evil.rb has works great for me. It should probably be
> called "replace" like the methods in Array, Hash, and String.
> evil.rb/become is just a more general form of the replace in
> Array, Hash, and String.
I agree that "replace" would be nice, but on the other hand I think the
fact that it is not guaranteed to work for all combinations of target
and source objects would be incompatible with that name. Plus there is
border cases where .replace works differently, I think, because it calls
to_ary.
"become" has been chosen because that is what this feature is usually
called in Smalltalk.