MultithreadingAnalyzer icon indicating copy to clipboard operation
MultithreadingAnalyzer copied to clipboard

Consider Contributing to Microsoft.VisualStudio.Threading.Analyzers

Open RehanSaeed opened this issue 5 years ago • 2 comments

The Microsoft.VisualStudio.Threading.Analyzers package has a very similar aim. It would be nice to see these two projects combined.

Furthermore, I've already raised an issue asking if Microsoft.VisualStudio.Threading.Analyzers has any plans to merge with the Microsoft.CodeAnalysis.FxCopAnalyzers and they say that there are intentions to do so.

Both of the Microsoft packages have very high usage. By contributing, your analyzers would get a lot more usage.

RehanSaeed avatar Sep 18 '19 08:09 RehanSaeed

Thanks for the proposition. However Microsoft.VisualStudio.Threading.Analyzers seems to be accompanying analyzers strictly related to the usage of Microsoft.VisualStudio.Threading package. Merging MultithreadingAnalyzers to Microsoft.CodeAnalysis.FxCopAnalyzers seems to be more logical because they are responsible for verifying usage of the BCL than third party libs. I've made a try to contribute to FxCopAnalyzers the but response time from the team responsible for those analyzers us very long so I've decide in the meantime to create my own package of analyzers related strictly to multithreading. Here's an issue for one of the analyzer (similar to one of the MultithreadingAnalyzers) that I've reported and offered my help https://github.com/dotnet/roslyn-analyzers/issues/2744

Currently, I'm struggling with one issue with MT1012 and MT1013. When I resolve it I'm going to ask Roslyn Gitter community to review my analyzers. Sam Harwell (@sharwell) has already offered his help with that https://twitter.com/samharwell/status/1173823729563885573

cezarypiatek avatar Sep 18 '19 15:09 cezarypiatek

seems to be accompanying analyzers strictly related to the usage of Microsoft.VisualStudio.Threading package

This was correct to start with, but we're moving away from that limitation. The analyzer package is now available for use even in projects that do not reference Microsoft.VisualStudio.Threading, and we'd certainly consider expanding on our work in that direction. For example, we fully merged the DotNetAnalyzers/AsyncUsageAnalyzers project into it. I believe the intent is to move all the threading-related analyzers from roslyn-analyzers into Microsoft.VisualStudio.Threading.Analyzers, and then somehow add the latter to the set of analyzer packages included in https://www.nuget.org/packages/Microsoft.CodeAnalysis.FxCopAnalyzers.

/cc @AArnott @mavasani

📝 Note that Microsoft.CodeAnalysis.FxCopAnalyzers does not contain any analyzers itself, but rather includes several declared dependencies on other packages that provide the analyzers.

sharwell avatar Sep 18 '19 16:09 sharwell