CodeRush for Roslyn 17.1.3

New Naming Assistant makes naming new members, variables and parameters easier.
May 18, 2017
New Version

Features

CodeRush for Roslyn

  • New Naming Assistant - This release introduces the CodeRush Naming Assistant. It makes naming new members, variables, and parameters easier. The Naming Assistant window automatically opens as you start typing a new symbol name. The suggestion list is filtered as you type. Suggestions are based on:
    • Identifier names used in the solution and in the current code block
    • The type of the identifier
    • The identifier role (member, variable, or parameter)
    • To select a suggestion use the up/down arrow keys. Press Enter to accept the selected suggestion.
  • New Declare Menu - This release introduces the Declare menu, a quick and easy way to add frequently-needed code to your types. The following declarations are now available:
    • Automatic Constructor generation (which also automatically initializes selected members and optionally generates encapsulating properties)
    • Delegate Members is useful when you want to surface a field’s or property’s members to this parenting type. This provider creates members that wrap around the contained field’s or property’s members. For example, if your type contains a generic List of strings (as a field or property), you can wrap that List’s Count property in its own property, easily surfacing it in your type
    • IDisposable Implementation generates the Dispose pattern, disposing the specified fields and properties
    • Equality Members generates two Equals methods and a GetHashCode override, and optionally generates equality comparison operator overloads
    • Override Members overrides virtual and abstract methods (e.g. GetHashCode)
    • Properties and Read-only Properties generate properties for the selected fields
    • Comparison Members generates a CompareTo implementation, individually comparing the specified fields, and optionally implements the IComparable<T> and IComparable interfaces
    • Missing Members adds any missing members (e.g., from an unimplemented interface or an inherited abstract class with abstract members) to the active class
    • Partial Methods implements any partial methods missing from the active class
    • ToString Override
  • New Code Metrics - Improve code quality and measure code complexity with Code Metrics. Appearing in the editor (to the left of member declarations), code metric values allow you to immediately spot code that is difficult to read or maintain due to its complexity. Three metrics are currently available: Maintenance Complexity, Cyclomatic Complexity and Line Count. DevExpress expect to extend this list in future releases.
  • New Clipboard History - This release introduces the Clipboard History list, providing complete visual access to your ten most-recent clipboard operations. Instantly paste with the Ctrl+number shortcut. Filter through the list just by entering the text you’re looking for. Ctrl+Shift+V brings up the Clipboard History list.
  • Refactorings and Code Providers
    • Convert to Function/Procedure - This code provider 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) and vice versa. This refactoring is available when the caret is on a return statement that returns a value inside a void proc (or 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 active class.
    • Move Type to Namespace - This refactoring changes the active type’s namespace and updates all references.
    • Introduce Using Statement - This refactoring replaces object creation and dispose code blocks with a using statement. This improves code readability and ensures that locally-used objects are properly disposed.
    • INotifyPropertyChanged Code Providers - DevExpress have added Introduce Change Notification and Convert to Property with Change Notification. These code providers help implement the INotifyPropertyChanged interface for the property at the caret.
    • Implement IDisposable - This code provider makes it easy to implement the dispose pattern in your types.
    • Encapsulate Property - This refactoring wraps specified field properties (declared by the field’s type) in new properties declared in the active class/struct. It's an easy way to surface properties from an owned field up to the containing class.
    • Smart Duplicate Line Improvements - DevExpress have extended the Smart Duplicate Line functionality with the following improvements:
      • Smart Duplicate Line features are now available in XAML.
      • The hex, octal, float, double, and decimal literals are now automatically incremented.
      • Smart Duplicate Line recognizes camel case parts of an identifier name and create links between similar parts of different identifiers.
      • Smart Duplicate Line recognizes enum element references and automatically cycles through those elements (if a pattern of enum element cycling is detected in the surrounding code).
      • If Smart Duplicate Line cannot recognize any pattern, it creates a text field around each identifier and literal in duplicated line.
      • When duplicating items in collection initializers and in parameter lists, a comma is added automatically.
      • You can now disable the 'smart' part of the Smart Duplicate Line feature so that it simply duplicates the line of code as is.
  • XAML Support
    • Convert Nested Element to Attribute/Attribute to Nested Element - DevExpress have added two new refactorings: Convert Nested Element to Attribute and Convert Attribute to Nested Element. Using them, you can extract an attribute from a XAML tag and make it a child element. You can also perform the reversed operation — inline a child element as an attribute of the parent tag. This refactoring may increase readability if you have too many attributes or a too deep nesting level.
  • Miscellaneous XAML Improvements
    • Navigation features now support XAML bindings.
    • Duplicate Line features are now available in XAML.
  • Visualization Tools
    • Region Painting - In v17.1, DevExpress have added the Region Painting feature, which adds low-contrast visual representation of #region directives, reducing visual noise where regions are used.
    • Output Highlighting - You can now highlight errors and warnings in the Output Window, making it easier to recognize important messages faster.
  • C# 7 and VB 15 Syntax Support - DevExpress have made several improvements to support the new C# 7 language:
    • The Expand\Compress Ternary refactorings now support C# 7 syntax
    • Smart Return ('r' template) now supports C# 7 syntax
    • Declare menu providers support C# 7 syntax
    • The Use Expression Body refactoring now works on constructors, destructors, getters and setters
    • We have added support for the new language features to the Debug Visualizer, including support for the new switch capabilities
    • Smart Duplicate Line now understands the new language features, including binary literals and digit separators
    • Expand Method, Expand Property, Expand Getter and Expand Setter refactorings all now support the new language features
  • Code Style
    • Namespace References Declaration Style - DevExpress have added a new Code Style rule for placing new Namespace reference imports/using declarations. You can now choose one of three styles: use fully qualified type names, place new imports/using references at the top of the file, or place new imports/using statements inside the active namespace.
    • Stop on Build Error - You can now tell CodeRush for Roslyn to stop building a solution if project building fails and an attempt to build a dependent project is made.
New Naming Assistant makes naming new members, variables, and parameters easier.

CodeRush

Visualize code and intuitively debug.

Got a Question?

Live Chat with our DevExpress licensing specialists now.