Silverlight 4 And Resharper 5 = Pain

5 commentsWritten on May 7th, 2010 by
Categories: resharper

I’ve been a longtime fan of Resharper and pretty much don’t even want to use Visual Studio without it.  But we’re in the process of upgrading to Visual Studio 2010, Resharper 5, Silverlight 4 and (later on) .NET 4 and yesterday we made a bit of a painful discovery.  It turns out that using Resharper 5 in Visual Studio 2010 actually makes your development experience worse than it is by default if you’re using Silverlight 4. 

The first problem is this:

rs5sl01 

If you use Action a lot in your code (and we do) then you’re pretty much screwed.  Resharper doesn’t recognize it and continually suggests changing it to a generic type.  Now, you can just press escape and go on working but it’s still very, very annoying.

Another thing that’s highly annoying is this:

rs5sl02

This is valid code, but Resharper doesn’t quite agree with us…  Which of course also makes solution-wide analysis completely useless:

rs5sl03

And this is in a solution which actually has no real errors whatsoever.

This should be fixed in Resharper 5.1, but unfortunately, that won’t be out until June.  We can only hope that the EAP builds of 5.1 start showing up ASAP because this situation really sucks for those who’re working with Silverlight 4.

So in case anyone of Jetbrains is reading this: please hurry up and get those EAP builds out the door so we can start using (and enjoying) your product again ;)

  • Emil Ingerslev

    I’ve fought so long with this problem, but actually i never realised that it was only in silverlight it happened. Our solution is telling resharper to ignore these errors every time they appear. They get real easy to spot by name in “errors in solution” view. After they are ignored, you can go back and focus on the real errors.
    But yeah i’m also really looking forward for the release fixing this! :)

  • http://hadihariri.com Hadi Hariri

    Hi Davy,

    Thanks for the feedback. Please feel free to log any issues at http://youtrack.jetbrains.net or contact me also via http://twitter.com/hhariri. It’s much more effective. Unfortunately I’ve only seen this blog post now since someone else pointed me to it.

  • http://blog.excastle.com/ Joe White

    As Emil mentioned, you can ignore individual errors in the “errors in solution” view. We have to do this because of false errors due to modopt (http://youtrack.jetbrains.net/issue/RSRP-179197). When we ignore these errors, they generally seem to do a pretty good job at staying ignored.

    So I’m not sure that solution-wide analysis would be useless in the face of this problem. Still, I can see how it would be a major pain. And ignoring the error in “errors in solution” doesn’t help when you’re actually editing one of the files with the false errors.

  • xvost

    Please, could you check which of SL4 standard libraries use the modopt?


    Eugene Pasynkov
    ReSharper Tech Lead
    Jetbrains s.r.o.

  • Pingback: Resharper 5.1’s Test Runner Is Broken | The Inquisitive Coder – Davy Brion's Blog