News for hackers. Stuff that matters.
Re:Functional Programming With Ruby by rlander on Tuesday July 26, 2011 @09:44PM (#2810338)
While I do agree with you that trying to shoehorn ruby into a pure functional style is a bad idea, I believe it's generally a good thing to try to write functional-style ruby: Functional in the small and OO in the large [1].

For example, you can have referential transparency in your methods, which will allow for easier debugging. You can also strive for simpler data structures and even freeze objects to make them immutable[2].

[1] http://www.johndcook.com/blog/2009/03/23/functional-in-the-s... [2] http://ontwik.com/ruby/better-ruby-through-functional-progra...

There are no comments on this comment yet.