-
Notifications
You must be signed in to change notification settings - Fork 510
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow configuration of SA0001:XmlCommentAnalysisDisabled #2192
Comments
This issue is a duplicate of #2191, with one big caveat. The compiler will not behave the way you expect when you have XML documentation disabled, and a large number of other rules will misbehave in subtle ways. I recommend reading over the documentation for SA0001, and using a ruleset file to disable the other rules which tend to be the original reason people turn off XML output (e.g. CS1573, CS1591). |
Thanks. Does that mean that I have to enable XML output no matter what, unless I want all sorts of strange effects? It's not really ideal. There's only a subset of projects I work on where switching on XML output makes sense, but I still want to use StyleCop in those projects for everything else. |
@adamralph Everything seems to work better if XML output is always enabled. We would have otherwise needed to make a bunch of exceptions in the analyzers and provide separate behavior for the case where XML output is disabled. I'm not sure why, but the setting affects the internal parsing behavior of the compiler in addition to the output. Also note that when XML output is disabled you'll face other bugs too, like dotnet/roslyn#2773. |
@sharwell OK, so it seems the problem is more deep rooted than this analyzer package, and is in Roslyn itself. Fair enough, I guess enabling docs when I don't need them isn't too costly. Shame that this paper cut has to exist though. |
For some projects, I don't want to enable XML documentation and I don't want this warning either. I should be able to disable this rule in StyleCop.json.
The text was updated successfully, but these errors were encountered: