My main reason? Refactoring. Over the years I've become very good at refactoring; I've actually been called a refactoring machine. I have a lot of experience refactoring really, really terrible code. Yes, this sucks, I have a history of picking the wrong job. Fortunately though, I also have some experience refactoring really nice code as well. The code that I'm working on now in Ruby is fairly new, and quite good. All the Scala code that I write is pretty good (room for improvement, but pretty good).
I can refactor so easily in Scala with huge confidence and I can't do that in Ruby at all. In Ruby:
- It takes a long time to make major refactorings.
- I'm never fully confident in my refactorings and almost always get annoyed by runtime errors.
- Sometimes the stack traces are all messed up and I can't figure out where my actual error is.
- Most code you run into isn't going to have enough test coverage to help anyway.
- For all the preachers of TDD and instant feedback - tests untimately/inevitably take (far) longer than the compiler. So I really don't have the instant feedback I need.
- If you skip refactorings in Ruby because they are hard, your code becomes harder and harder to refactor. This goes for statically typed languages as well, but, it's a lot harder with Ruby, especially considering the points above.
- Ad infinitum...
In my next post I'm going to cover a bunch of major refactorings I just did to my Lexer, and how easy it was.
4 comments:
So you got a job to work on Scala?
no. i dont think i suggested that, did i? i'm not looking for a new job. im more focused on returning to school.
totally agree with this article
Your Best Choice! wow power leveling and wow gold wow gold|*|wow power leveling|*|http://www.saleveling.com|*|fgf554
Post a Comment