Challenges for
automatic refactoring

  • send
  • eval
  • undef etc.
  • alias
  • open classes
  • attr_*
  • No variable declarations
<< >>



Comments. Some people say that it's impossible to do automatic refactoring in Ruby. There's something in this. There are many challenges to be overcome if this is to be practical.

The highly dynamic nature of Ruby makes automatic refactoring difficult. And there will always be fragments of Ruby code that cannot be automatically refactored (unless you add true artificial intelligence).

But I have two compelling arguments here. If you're a skeptic, neither one will convince you.

  • Any tool that can do 90% of the work or can function correctly 90% of the time is still better than working in a purely manual way.
  • Smalltalk is also a very dynamic language, and its refactoring browser is legendary. If they can do it, why can't we?