R# 8 and Code Contracts

Hy Guys,

does R# and Code Contracts work together?

I installed :

http://visualstudiogallery.msdn.microsoft.com/1ec7db13-3363-46c9-851f-1ce455f66970?SRC=Home installer and

http://visualstudiogallery.msdn.microsoft.com/02de7066-b6ca-42b3-8b3c-2562c7fa024f  .vsix for Visual Studio 2012 update 3

And I tried sample from this video


but it doesn't work :(  When i disable R#, Code Contracts works.

I tried doing this http://www.infinitec.de/post/2010/11/18/Using-Code-Contracts-Visual-Studio-and-with-Resharper.aspx   but it didn't help.

Comment actions Permalink

I can confirm this for Resharper 8.0. I followed the steps detailed in the given link (http://www.infinitec.de/post/2010/11/18/Using-Code-Contracts-Visual-Studio-and-with-Resharper.aspx), installing Microsoft.Contracts.xml in the ReShaper\v8.0\Bin\ExternalAnnotations\Microsoft\mscorlib directory and restarted VS. Resharper still flags name[0] as a possible null.

Comment actions Permalink


did u had to create mscorlib directory inside Microsoft directory or it was already there? I don't have that directory.

But I found it inside .NET Framework directory

C:\Program Files (x86)\JetBrains\ReSharper\v8.0\Bin\ExternalAnnotations\.NETFramework\mscorlib

anyway I am tring to get extended parameter information which they showed inside video that I posted before

So this is what they get:


and this is what I get:


Comment actions Permalink

I added the directory. I tried several different combinations trying to make it work, but had no success.

My guess is that the XML structure since R# 5 has changed some, so that the article code no longer works.

Comment actions Permalink

yeah, that's why I posted question here I hope some one from Jetbrains could help us :)

Comment actions Permalink

It's August, I assume Admins are still on vacation?


Please sign in to leave a comment.