A look at Ruby 2.0(rubysource.com) |
A look at Ruby 2.0(rubysource.com) |
sudo apt-get install libyaml libyaml-dev
or for you hat-wearing folks sudo yum install libyaml libyaml-devel
should work just fine.I think this could more easily allow for the use of multiple support libraries (like ActiveSupport) without having to worry about them clobbering each other.
What we did was create one gem for each specific special behavior of the app, were we declared some methods as extension points which the base app should call, in that scenario prepending methods would be useful, we could declare dummy empty methods to be overwritten later on by a module.
What we needed to do because of the lack of prepending modules was that each module implementation should implement all of the extensions points even when it was not needed, so, some times we had some dummy empty methods on one of the specific modules, i would have preferred to have those dummy methods on the main project itself.
Currently, you have to attempt to load baz before you load foo, and then not load foo's implementation of bar, if baz loaded successfully. In the future, you could just prepend foo, and so if baz was already loaded, it doesn't overwrite its optimized implementation. If baz wasn't loaded, then when it does load, it would overwrite the prepended implementation properly.
This just frees you up from having to worry so much about load order. It's not a huge feature, but it's a nice little quality-of-life change.