It's hard to imagine that almost a year has gone by since my jab at Resharper's 3.0 lack of support for .NET 3.5. Yesterday I finally got around to installing thew newly released Resharper 4 and I'm more then blown away by some of the new features. Not only does it fully support the new syntax (lambdas, linq, anonymous types and so on), but it offers some nice new features.
The first thing I noticed was that the "Reformat" feature - which i use a lot - has been renamed to "Cleanup Code" and not only does more, but also supports profiles - so different code cleanup profiles can do different things. One thing i haven't figured out yet is how to edit the 2 default profiles
The next thing that surprised me was that Resharper suggested I use object initialization. So given:
task t = new Task();
t.Name = "Test";
and hitting alt-enter, resulted in:
Task t = new Task {Name = "Test"};
Similarly, Resharper suggests using implicit type variable. David already blogged about this - and like him, I also disabled this suggestion. However, if you're with JP on this, you'll certainly appreciate the helpful tip.
One feature I'm on the fence about is their JetBrains.Annotation assembly. With it, you can decorate your members usings JetBrain-specific attributes to provide even better integration. For example, given a method that behaves like string.Format, I can add a StringFormatMethod attribute:
[StringFormatMethod("key")]
public void Put(string key, params object[] args) { ... }
This then allows Resharper to provide additional information, so if I do:
Put("testing {0}, {1}, {2}", 1, 2);
Resharper will tell me that {2} doesn't have a matching argument. It's a neat feature, but there's something strange about adding a JetBrain's 'dll to my project.
Generally, I think Resharper's a must-have. If you have an older version and aren't working on 3.5 code, then save your money. However, if you're doing even a little bit of 3.5 programming, then this thing is totally worth it. I have three complains/concerns.
First, I wish more of the windows docked. For example, I wish "Recent Edits" was dockable. While we're on the topic of recent edit, Resharper should look at what e-TextEditor does and provide THAT amazing functionality.
Secondly, each version of Resharper gets progressivley more complex. There are more shortcuts (like the new ctrl-shift-enter) and more configuration. The barrier to entry is starting to get a little high. Although the couple hours you might spend configuring it are quickly made up.
Finally, price. I can't help but feel that, despite the amazing value, upgrading from 3.0 to 4.0 should be less than $100. Maybe I feel that way 'cuz 3.0 was a bit of let-down for me (I know it wasn't for everyone, especially VB.NET developers), and also because I think everyone should use it.
What are you waiting for? Get your free 30 day trial now.
P.S - I downloaded that sucker at 8meg/sec from their Rackspace server - that's insane (rackspace is in Texas, I'm all the way north in Ottawa). And while I still love Rackspace, I'm a far bigger fan of SoftLayer. Same thing but $600/month cheaper, $0.20/gb instead of like $2.00, and amazingly useful iSCSI.