Enable turning off Roslyn Code Fixes
I would like to speed up Visual Studio 2015 by disabling the analysis of my sourcecode by Roslyn (code analysis, code fixes, analyzers, etc) when I am working in C# projects. In previous releases of Visual Studio there were two options in the Tools menu >> Options >> Text Editor >> C# >> Advanced:
- Underline errors in the editor
- Show live semantic errors
I am a user of ReSharper, so I do not need this functionality. The reason I think Roslyn is causing the slow-down is that when I use the same version of ReSharper in VS2013, I do not see the slow-downs that I experience in VS2015 (spinning wait cursors, flickering Intellisense menus, etc).
I have seen various suggestions on the Internet, but they do not appear to be the same idea as a nice checkbox would be in the Tools menu >> Options dialog.
Here are the suggestions I have seen to turn off parts of Roslyn:
1) Disable using the "Squiggles" registry key: https://m.reddit.com/r/VisualStudio/comments/42lcal/any_way_to_completely_disable_live_code_analysis/
2) Turning off Analyzers in the active rule set: http://stackoverflow.com/a/31357300/35133
But none of these are "official" Microsoft suggestions, and it would be nice to just be able to eliminate that churn in the IDE period.
Caleb D commented
I see constant CPU usage from VS (17% on a quad core system), even with Resharper disabled. If I close all my open code windows, then CPU usage drops to almost zero. Otherwise my fan is running constantly. I have solution-wide analysis disabled for both C# and Basic.
On a freshly opened VS, it is ok, but things get worse as I leave visual studio open for hours. I have UI lags where VS just doesn't respond for a few seconds. Maybe something else, but...
This is with VS2017 latest update as of Oct 16th, 2017. Solution has about 200 projects (large API surface).
Please put in the option to completely disable Roslyn in VS2017! I experience lag-**** when working with large solutions with the current ReSharper enabled. It has been a real headache ever since VS2015.
Jerry Hewett commented
Note to the Developer Tools division: Stop opting developers INTO features they don't want.
A lot of us don't want Roslyn Code Analysis, and don't even want it installed OR available in Visual Studio.
A lot of us don't use IntelliSense, and don't ever want to see warnings or errors related to Intellinsense. A lot of us don't use Azure, and don't want anything related to Azure installed and turned on by default.
Stop trying to force developers to use things they don't want, don't need, and aren't interested in. Give us a checkbox -- LIKE THE INSTALLER USED TO DO -- to let ** US ** decide what we want and don't want in Visual Studio.
I do not like some Roslyn recommendations.. so I prefer to have custom rules. I am not able to do that in VS2015 Update 3 for .Net Core libraries (net461)... even with Resharper!
David McClelland commented
IMHO, the new checkbox in VS2015 Update 3 which allows you to toggle off/on the "Enable full solution analysis" option is a step in the right direction (https://msdn.microsoft.com/en-US/library/mt709421(VS.140).aspx) - but it still doesn't enable you to eliminate ALL solution analysis.
David McClelland commented
I can see this also being useful for developers who prefer to "just code" in Visual Studio instead of having the IDE do a lot of the Roslyn analysis of "unnecessary usings", "unnecessary reference", etc.