From: Shadowfirebird Date: 2011-03-08T22:15:54+09:00 Subject: Re: Duplicate methods removal in Ruby's TODO ? Excerpts from David Unric's message of Tue Mar 08 12:30:06 +0000 2011: > Hi, > > as you know for sure, Ruby defines several method aliases of base > classes to appeal/(make it easier to grasp) programmers comming from > different languages (Perl, Smalltalk, Lisp etc.). > > Array: > 'slice' and '[]' > 'collect' and 'map' > 'inspect' and 'to_s' > > Enumerable: > 'find_all' and 'select' > 'find' and 'detect' > 'entries' and 'to_a' > 'inject' and 'reduce' > 'include?' and 'member?' > > Hash: > 'store' and '[]' > 'each' and 'each_pair' > 'key?' and 'has_key?' > 'value?' and 'has_value?' > 'length' and 'size' > 'merge' and 'update' > > ... > > Just curious about possible removal of method aliases in a future ? I > know it would be very difficult decision to break backward > compatibility, but because these are synonyms/aliases it won't be too > hard to write conversion tool for existing sources. > > Is there same intention to clean Ruby's core libraries ? > When'll be the time, Ruby would need no more to attract programmers from > different envirnoments and start with cleaning out ? Good gods, I hope not. Where would the advantage be, if these methods are just aliases for each other? And think of the number of programmers you would alienate!