3 ms·
Obviously you don't have much experience with IDEs and statically typed languages, which is a shame because they make our life so much easier. There are no edge
by tsss 7y ago
Obviously you don't have much experience with IDEs and statically typed languages, which is a shame because they make our life so much easier. There are no edge cases. And even if there were the IDE can show you the refactoring and you can decide on a case-by-case basis.
> what happens when you change a class name -> forget you do it before saving the file -> go to another file and try to change the class name there but have a typo -> go back to the original file and save the change?
A good IDE does not care if you save the file or not. It is always up-to-date. Renaming a class in just one file is also impossible, since the IDE will do refactorings atomically over the whole project. But lets just assume you somehow managed to fuck it up that badly (things can always go wrong): You will still realize your error almost instantly because a statically typed language does not defer such checks to runtime. The program wouldn't even run anymore.
By far the biggest issue with automatic refactoring is accidentally renaming stuff in comments (or forgetting to do so) because I'm too lazy to look at every single place. But find&replace has the same problems.