From: "RadosÅ‚aw BuÅ‚at" Date: 2008-02-29T03:02:59+09:00 Subject: Re: Proposed Solutions - Was [ Re: Monkeypatching is Destroying Ruby ] On Thu, Feb 28, 2008 at 6:10 PM, Avdi Grimm wrote: > In the mean time, a quick hack: http://pastie.caboo.se/paste/158825 > > Example: Avdi, sorry but it isn't any solution for problem. You get warning or exception and method won't be overriden. Imagine that you want use 2 libraries that collide and you get sach a error. Is it usefull? Another problem is that there are at least two cases why you are opening existing class and adding features to them: #1 You open class to just add new method and your library depend on it for example class String def underscore #... end end When other library do the same there is problem because first library use diffretent method than defined by itself. #2 You open class to knowingly override existing method to change/enhance it class ActiveRecord::Base def find(*args) #... end end The same problem here: if other library/plugin/whatever do the same after our change then we have problem. > James, Sometime ago Rick Olson wrote this: > > http://weblog.techno-weenie.net/2007/12/19/adventures-in-rails-debugging Great story. My opinion is rails and many other libraries use too much MP. This story shows it. Opening String class just to add stupid "underscore" method? So evil. -- Rados³aw Bu³at http://radarek.jogger.pl - mój blog