The process of removing duplicate code is called code consolidation. The result of code consolidation is a single code block that replaces a specific duplicated code in several locations (different files or projects). The resulting consolidated code block is functionally absolutely the same as all duplicated code blocks it replaces.
Read more…
CodeRush ships two standalone programs that do not require the Visual Studio IDE to be running for duplicate code detection analysis:
- Duplicate Code Analysis windows app
- Duplicate Code Analysis console app
Both applications can be used outside of the IDE to find duplicate code inside a specified solution. These applications are located inside the Plug-ins folder of your IDE Tools installation. You can find the windows application in the Start menu as well:
Read more…
The Duplicate Code tool window allows you to review the duplicate code found in your entire solution. The tool window is available via the DevExpress | Tool Windows | Duplicate code menu item.
If the duplicate code analysis has been started, you will see the analysis results in the Clusters list on the left, otherwise, you can click the “Run duplicate code analysis” button to perform the duplicate code search. This is what it looks like:

Read more…
CodeRush Duplicate detection runs automatically inside Visual Studio IDE in a background thread. To enable it, go to the Duplicate Code options page in the Options Dialog and toggle its availability. Note that you should also have the Code Issues Analysis feature enabled. Once you enable detection, it starts scanning your solution for code duplication. You will see an animated icon in the lower right corner visually indicating the progress of duplicate code analysis:

Read more…
This is a blog series overview of the Duplicate Detection and Consolidation (DDC) feature shipped in DevExpress CodeRush Pro productivity tool for the Visual Studio IDE.
Background
Duplicate code, or sometimes referred to as a clone, is a program source code fragment that is very similar to another code fragment. A code clone may occur more than twice, either within a single program or across different programs owned or maintained by the same group of developers. Code duplication is considered an expensive practice that should be avoided because it complicates the maintenance and evolution of the software.
Read more…
Cause:
The Member is not implemented code issue of the warning type is shown for the members that do not provide an implementation. Not providing an implementation may be a sign of incomplete code.
The code issue is shown for non-interface, non-abstract, non-virtual, non-extern members – both methods and properties. It is not shown for constructors and destructors of a class.
Read more…
We already reviewed the refactorings for anonymous methods and lambda expressions and know how to deal with these language structures. Now its time to review what Code Issues for anonymous methods and lambda expressions CodeRush Pro provides.
An interface is a code structure that has no concrete members and similar to an abstract class. An interface can contain public members such as methods, events, properties and indexers, but these members do not provide any functionality. Instead, they define items that must be made concrete within all classes that implement this interface. This means that an interface can be used to define what a class must do, but not how it will achieve it.
Read more…