Thursday, December 08, 2005

Refactoring Ruby

Refactoring and Code Completion- two things about Eclipse that are very hard to give up when typing in Ruby. Jon Tirsen's post sums up the challenges in Ruby pretty well, although there are some innovative approaches for doing things like a rename, if you have a fully automated test suite that will throw deprecation warnings.

It's not like Java or (C#) is completely immune to these kinds of things. Once you start writing framework style code (like an O/R mapper or something with great gobs of XML splattered about) and using reflection and the Class class all of the time, a lot of the type safety disappears. In most cases, a class cast exception is no better than what would happen in Ruby. The concept of method_missing is also a neat way to deal with what happens when duck typing fails.

In any case, the ascent of dynamically type languages continues. Python, which appeared to be the heir to Perl, is rolling with some well made new web frameworks. Ruby is selling more books though, according to Tim O'Reilly. The debate Ruby vs. Python really doesn't matter toooo much, although I suspect that the Ruby will end up in more enterprise locations, once people like Justin and Stu get the Enterprise kinks worked out.

Anyway, I know code completion and refactoring make me a lot more productive. It is an open question whether the other gains of Ruby/Rails make up for that loss.

0 comments: