Visual Studio 2005 vs Eclipse – again, but this time with ReSharper…

A while ago, I wrote a blog entry about how Eclipse and Visual Studio 2005 stacked up against each other. Some of my quibbles with Visual Studio 2005 were due to my ignorance, but some were significant (from my point of view) missing features. Well, since then many people have recommended that I take a look at ReSharper. I requested a 30 day eval licence (as well as requesting a full free MVP licence by email – those people at JetBrains are very nice, thank you very much!) installed it, and after a quick look decided it would be worth revisiting my previous blog entry, to see just how many of the problems have been solved by ReSharper.

  • “Open Type” in Eclipse: yup, solved by ReSharper with “GoTo Type” – shortcut Ctrl-N
  • “Open Resource” in Eclipse: ditto, “GoTo File” – shortcut Ctrl-Shift-N
  • Overloads in Intellisense: amazingly, yes! I really hadn’t expected this one
  • “Organise imports” in Eclipse: yup, “Optimize Usings” – shortcut Ctrl-Alt-O
  • Unit test integration: see later
  • Refactoring: well, Extract Method still isn’t as smart as Eclipse, but there’s a lot more available than in vanilla VS2005. Only time will tell how much is really useful in practice
  • Navigational Hyperlinks: after my original blog entry was posted, readers explained the VS2005 equivalents. ReSharper provides some more navigation options though, including Ctrl+Click to navigate to the declaration, which will be handy for my muscle memory.
  • SourceSafe integration: not an issue for me now, as I use Subversion. AnkhSvn is pretty good, but I haven’t used it enough to really compare it with Subclipe (or Subversive)
  • Structural differences: no changes that I’m aware of
  • Compile on save: again, no change. After a couple of years with Eclipse, I’m really going to miss this.
  • Combined file and class browser: no changes that I’m aware of. I suspect the ReSharper guys could do this one. Maybe the next release? :)

I said I’d come back to unit testing. Previously, I’ve used TestDriven.NET but I’ve never been particularly happy with the lack of real IDE integration. It’s not too bad for NUnitGUI to come up in a new window, but it’s not as nice as the JUnit support in Eclipse. ReSharper has the same kind of integration as Eclipse, which is very welcome. I gather you need a different plug-in to run VSTS test cases, but that doesn’t bother me. There’s one thing which TestDriven.NET gives me which I’ll miss, however – NCover integration. Maybe I need to look into writing an NCover plugin for ReSharper… it would certainly come in handy. (I should point out at this stage that I don’t have the equivalent in Eclipse.) Of course, there’s nothing to stop me from using TestDriven.NET and ReSharper in the same, but they are both commercial products (for non-personal use at least). I’m not sure that NCover integration is enough to make it worth buying TestDriven.NET if you’ve decided to get ReSharper.

So, why wouldn’t you get ReSharper? Well, it hurts performance a bit. I can’t say by how much, or whether it depends on the size of solution. I’ve only tried it on a small solution, and only briefly at that. It’s definitely more sluggish than normal, but far from unusably so – the features above will more than make up for it, I’m sure, and those are only the ones I happened to highlight in my Eclipse comparison. There are many more features, and it looks pretty tweakable. (It does some extra highlighting in the editor that I’ve turned off, for example.)

In short, it looks fabulous so far. I’m very much looking forward to using it more, and hopefully persuading colleagues (and those who hold the purse strings, of course) of its value. As a mark of how much I expect to use it, I’m not changing the shortcut keys to match those in Eclipse. If I expected to just use it myself, I’d do so – but as I expect to see it in use on colleagues’ machines, I’d rather use the default shortcuts where possible.