ReSharper 8 EAP Build: JIT Edition

Hadi Hariri

Well it’s here. With only one day left for the previous EAP to expire, we’ve managed to get a new EAP build. All is fine. Download the latest EAP now. Let’s see what’s in store in this build.

Move Instance Method Refactoring

This frequently requested refactoring allows moving instance methods from one class to another. Take the sample class below:

Before applying Move Instance Method refactoring

We can see that the Print method uses an instance field. Invoking an Move Instance Method refactoring on this method results in ReSharper prompting us for the destination class we want to move the method to. However, in addition to moving the method, it also wraps the field, in this case with a property, and passes in the current class as an argument to the method, resulting in

After applying Move Instance Method refactoring

Note that when it comes to choosing destination classes, this refactoring only offers those that are members of the original class. It’s also worth pointing out that Move Instance Method currently only supports C# but we’re working to ensure VB.NET support in subsequent builds.

Inspecting XAML Grids

We’ve added several new code inspections and quick-fixes related to the usage of grids in XAML markup. Although present in one of the previous EAP’s we’ve now polished it up for the current release and ready to talk about it some more.

With ReSharper 8, there’s no way you can declare a control that sits in a non-existent grid row or column and get away with it:

ReSharper detects a usage of an undefined row

What we have here is a parent grid with two defined rows and a nested grid referencing a grid row that doesn’t exist. In addition to helping you actually spot the problem, ReSharper 8 includes a quick-fix that will insert all the missing row definitions if that’s the way you want to sort out the issue:

Quick-fix to add missing row definitions

It adds the missing definitions without moving the caret around, and you stay exactly where you had been before the fix was applied. If you’re working with a complex layout and you stand at a grid row property that’s several screens away from row definitions, that saves you quite a bit of navigating through your code.

There’s also a new inspection that fires up whenever a control within a grid doesn’t specify a row or column number, and suggests a fix. Note that this inspection isn’t fired for the first control in a grid since developers often deliberately leave columns and rows for the first controls unspecified.

Quick-fix to add a missing grid row property value

We’re not only adding code inspections and corresponding quick-fixes but standalone context actions as well. Specifically, there are new context actions to add or remove a row or column definition before or after the current definition, as well as one to remove the current row or column definition.

ReSharper can help if you want to add or remove a column definition

XAML Refactorings

We have added a whole bunch of refactoring and enhancements for XAML, including Extract Style Refactoring, collapsing empty tags, code cleanup, styling daemons, and more. We’ll be covering these in more detail in a separate blog post.

UI Enhancements, Bug Fixes and More

Some touch-ups have been applied to the ReSharper UI where most of the older controls are now replaced with WPF ones. We’ve also fixed numerous bug reported since the previous EAP (thanks everyone for these reports and keep them coming). Additionally, two somewhat annoying bugs have also been fixed with this release, related to MSBuild. The first one is Conditional References with MSBuild and the second has to do with ResolveAssemblyReferencesDependsOn build task.

We hope you enjoy this latest release of ReSharper 8 EAP and as always, welcome bug reports and feedback. Download the latest EAP now.

Comments below can no longer be edited.

6 Responses to ReSharper 8 EAP Build: JIT Edition

  1. Alexander says:

    May 31, 2013

    Have you updated command-line tool as well?

  2. beavis says:

    May 31, 2013

    When will be release?

  3. Julien Lebosquain says:

    May 31, 2013

    Glad to see all these XAML helpers built in: I can retire GammaXaml for R# 8.
    The new WPF tree in Find Usages lacks some contrast that was here previously: line numbers and “(number of items)” were in different colors IIRC, making the tree more readable.
    Overall, this EAP feels a lot smoother than the previous one. Keep up the good work!

  4. Jura Gorohovsky says:

    May 31, 2013

    Looks like we haven’t updated the link to command-line tools for some reason. Apologies. Looking to fix this later today.

    We’re aiming to release in July.

    Thanks! Here’s hoping that you’ll come up with more great plug-ins instead of GammaXaml )

  5. Dave Hanson says:

    June 3, 2013

    Is there typescript support yet?

  6. webdev says:

    June 5, 2013

    Maybe a little bit typescript…


Subscribe to .NET Tools updates