Top "Refactoring" questions

Refactoring is a disciplined technique for restructuring existing code, altering its internal structure without changing its external behavior.

Is there a key combination in Xcode to implement a Protocol?

In Visual Studio if I define a class to implement an interface e.g. class MyObject : ISerializable {} I am able …

objective-c xcode refactoring code-generation
Which is faster? Comparison or assignment?

I'm doing a bit of coding, where I have to write this sort of code: if( array[i]==false ) array[…

performance optimization refactoring
Any way to surround code block with Curly Braces {} in VS2008?

I always find myself needing to enclose a block of code in curly braces { }, but unfortunately that isn't included in …

c# visual-studio-2008 refactoring resharper code-snippets
How much duplicated code do you tolerate?

In a recent code review I spotted a few lines of duplicated logic in a class (less than 15 lines). When …

refactoring coding-style dry code-duplication
What tools and techniques do you use to find dead code?

What tools and techniques do you use to find dead code in .NET? In the past, I've decorated methods with …

c# .net refactoring code-analysis
Alternatives to @VisibleForTesting

I understand that @VisibleForTesting is not desirable because it changes the interface of a class just for testing purposes. Ideally …

refactoring easymock
Refactor rename broken in Intellij IDEA

Somehow, I managed to break my refactoring capabilities in Intellij IDEA 12. I have somehow disabled it for my project. Renaming …

intellij-idea refactoring rename
Refactoring C/C++ in Vim (e.g. method extraction like in Eclipse)

Are there any plugins or built-in methods in Vim for performing refactoring on C or C++ code, something like the …

c eclipse vim refactoring vim-plugin
Coding Katas for practicing the refactoring of legacy code

I've gotten quite interested in coding katas in recent months. I believe they are a great way to hone my …

refactoring legacy-code