CodeRush for Roslyn, v. 16.2.3 is Available

Continuing our 45-day sprint/release cycle, today we release another update to CodeRush for Roslyn. Highlights of this release include powerful new refactorings & code providers, along with enhancements to Smart Duplicate Line.

New Refactorings and Code Providers

  • Convert to Function – Allows you to easily convert a method that returns void into a function that returns the appropriate type (matching the type of the expression returned). I find myself frequently using this refactoring because it's fast, smart, and I can invoke it from inside the method (with the caret on a return statement). There’s no need to reach for the mouse or move the caret up to the declaration. Here’s what it looks like:

  • Convert to Procedure – This code provider is the opposite of Convert to Function. It converts a method that returns a value of any type to a proc that returns void (or a Sub in VB).
  • Extract Interface – This refactoring creates an interface based on the public members of the active class, and modifies the active class so it implements the extracted interface. 
  • Widen Scope (promote to field) - Use this to move a local variable declaration from inside a method body out to become a private field of the parenting class.

Smart Duplicate Line Gets Smarter

In our last release, we introduced Smart Duplicate Line (Shift+Enter). This feature is a real time saver, allowing you to create new lines of code modeled on existing lines of code. Smart Duplicate Line (SDL) looks for patterns in the surrounding code, and attempts to predict the parts you’re likely to change. As a result, SDL is great for declaring constants, enum elements, properties, and POCOs.

In this release, we make SDL even smarter.

For starters, SDL now works in XAML:


And SDL now recognizes (and increments) patterns of numeric primitives of type integer, double, decimal, octal, float, and hex:

SDL - Enums Hex

And SDL can cycle through enum elements in the code automatically:

SDL - enum cycle

SDL is one of my favorite new features. Be sure to try it out (Shift+Enter) and let us know what you think, and also send us your suggestions for how we can make it even smarter.

Other Enhancements

  • Paste Replace Word – Replaces the identifier under caret with the one on the clipboard in a single keystroke. Press Ctrl+B when the caret is on an identifier to immediately replace it with the contents on the clipboard.
  • Navigation features now support XAML bindings.
  • We added submenu support to the Code Actions menu, offering contextually-related actions (e.g., contract actions, spelling suggestions, etc.) in a single submenu (thereby cleaning up the main Code Actions menu).

  • We have added the ability to collect a marker and immediately paste clipboard contents at the target location using a single keystroke (Shift+Esc).
  • We have added a menu item allowing you to clear all markers dropped in the document.
  • You can now group Code Issues and References by folder containing the source code file.


We also addressed a number of reported issues. As always, we welcome your feedback.

You can always download the latest version of CodeRush for Roslyn from the Visual Studio Marketplace. Give it a try and let us know what you think!

Free DevExpress Products – Get Your Copy Today

The following free DevExpress product offers remain available. Should you have any questions about the free offers below, please submit a ticket via the DevExpress Support Center at your convenience. We’ll be happy to follow-up.
James S K Makumbi
James S K Makumbi


I have been using copy and paste THE WHOLE TIME!!

The reason we code is to automate repetitive tasks. So when you spend thirty seconds writing duplicate lines of code.... there is some guilt, self doubt, a "code whiff" (a false code smell) and self loathing.

Many a time have I gone off on a quixotic tangent try to code a clever data structure to replace the duplicate lines of code.

Thanks for scratching that itch. Now go wash your hands!!

14 December 2016
Dom Sinclair
Dom Sinclair

Great to see CRR starting to gain all the goodness that was in classic, really missing the Code Rush Training window though (an immeasurable help in trying to remember some of the crazy acronyms appointed to my own templates). Do you see that being implemented any time soon?

15 December 2016
Mark Miller (DevExpress)
Mark Miller (DevExpress)

Hi Dom,

Porting the CodeRush training window is currently on our backlog. It is unlikely to be implemented in the next 45 days, however it is likely to ship in the next year. At this time I am unable to get you a tighter window for expected delivery..

16 December 2016
Stephen Kennedy 3
Stephen Kennedy 3

Will CR Classic be upgraded to 16.2, or is version 16.2 just for CR for Roslyn? Any idea how long CR Classic will be continuing to get these kind of updates? Is there a time where CR Classic will no longer get updates like this?

20 December 2016
Mark Miller (DevExpress)
Mark Miller (DevExpress)

Hi Stephen,

We expect CR Classic to continue to receive maintenance updates (correcting reported issues) in the coming years, however we do not expect CRC to receive any additional features in that time frame.

27 December 2016

Great stuff!

What about "Clipboard History"?

Is it planned to be ported? Any timelines?

28 December 2016
Mark Miller (DevExpress)
Mark Miller (DevExpress)


Clipboard History is expected to be ported later in 2017.

28 December 2016
Yetao Chen
Yetao Chen

Hi Mark,

When will CRR support HTML & JS ?

and also when will code formatting be ported?

Thank you

19 March 2017
Mark Miller (DevExpress)
Mark Miller (DevExpress)


HTML & JS support across all CodeRush features is actively in development, expected to appear incrementally across different features (test runner, structural highlighting, templates, etc.) in future sprints. We currently have code formatting for XAML and code cleanup for C# & VB, and in the next sprint we expect to start development on code formatting.

26 March 2017

Please login or register to post comments.